c********e 发帖数: 417 | 1 My boss asked me to write a shell program to do the following things:
1. find the changed files during a day. I guess it could be accomplished
by 'find ' utility.
2. copy those changed files to another machine across a network. Is 'ftp'
usable? If so, how to use ftp? How to disable the prompting and provide
it with userID and password?
Or there is some other way to do it instead of 'ftp'?
3. the script has to run every night automatically. I heard 'cron' can do
that, but I have ne |
j*****g 发帖数: 980 | 2 man cron
man crontab
search google for cron
....
【在 c********e 的大作中提到】 : My boss asked me to write a shell program to do the following things: : 1. find the changed files during a day. I guess it could be accomplished : by 'find ' utility. : 2. copy those changed files to another machine across a network. Is 'ftp' : usable? If so, how to use ftp? How to disable the prompting and provide : it with userID and password? : Or there is some other way to do it instead of 'ftp'? : 3. the script has to run every night automatically. I heard 'cron' can do : that, but I have ne
|
c********e 发帖数: 417 | 3 OK, then. I figured out how to use cron. But I still have no idea how
to transfer a file to another machine in shell script.
Anyone knows? Thanks!
【在 j*****g 的大作中提到】 : man cron : man crontab : search google for cron : ....
|
c**t 发帖数: 2744 | 4
You've already known these stuff. Read man pages instead of
asking help.
【在 c********e 的大作中提到】 : My boss asked me to write a shell program to do the following things: : 1. find the changed files during a day. I guess it could be accomplished : by 'find ' utility. : 2. copy those changed files to another machine across a network. Is 'ftp' : usable? If so, how to use ftp? How to disable the prompting and provide : it with userID and password? : Or there is some other way to do it instead of 'ftp'? : 3. the script has to run every night automatically. I heard 'cron' can do : that, but I have ne
|
c*****t 发帖数: 1879 | 5 1. like others have suggested, read man pages of them first.
the commands you discribed can do the job. Just a note
that you can use shell script to generate a ftp script
in .netrc (which you may have to create a special account for it)..
Or you can use expect script. Or you can tar the files
first if they are not too big.
2. you may also want to try out uucp, which I have no idea
of using.
3. You can do NFS mount and.
【在 c********e 的大作中提到】 : My boss asked me to write a shell program to do the following things: : 1. find the changed files during a day. I guess it could be accomplished : by 'find ' utility. : 2. copy those changed files to another machine across a network. Is 'ftp' : usable? If so, how to use ftp? How to disable the prompting and provide : it with userID and password? : Or there is some other way to do it instead of 'ftp'? : 3. the script has to run every night automatically. I heard 'cron' can do : that, but I have ne
|
j*****g 发帖数: 980 | 6 man ncftpput
man ncftpget
【在 c********e 的大作中提到】 : OK, then. I figured out how to use cron. But I still have no idea how : to transfer a file to another machine in shell script. : Anyone knows? Thanks!
|
T********r 发帖数: 6210 | 7 $ man rcp
it's simple.
【在 c*****t 的大作中提到】 : 1. like others have suggested, read man pages of them first. : the commands you discribed can do the job. Just a note : that you can use shell script to generate a ftp script : in .netrc (which you may have to create a special account for it).. : Or you can use expect script. Or you can tar the files : first if they are not too big. : 2. you may also want to try out uucp, which I have no idea : of using. : 3. You can do NFS mount and.
|
s***t 发帖数: 195 | 8 or scp. it's secure.
【在 T********r 的大作中提到】 : $ man rcp : it's simple.
|