Yet another solution:
Use the command line "ftp" program.
It allows you to setup a .netrc that can contain the user/pw of several ftp servers.
default login anonymous password user@site
The last line of one of my cron jobs looks like this: (runs as root)
ftp server1.mydomain.myorg < ~/ftpscr
and you can do anything in "ftpscr" that you can do from the ftp> prompt.
my ftpscr
cd //border/cache/email
bin
prompt
lcd /tmp
mput *.Z
quit
your ftp script might be as simple as:
ascii
get /dir/subdir/test.txt
quit
BJD wrote:
>
> I need to retrieve a file (via cron) which resides on an FTP server
> requiring a username and password.
> In Netscape entering a URL of
> ">pass@ftp.ftpsite.com/dir/subdir/test.txt">ftp://user:">pass@ftp.ftpsite.com/dir/subdir/test.txt
> works nicely *but* how can I accomplish the same thing from the command
> line? And yes, I've read the 'man' but am still clueless...
> --
> Brian J. Dowd
> 73, W1DOC
> --
> To unsubscribe: mail ">majordomo@ale.org with "unsubscribe ale" in message body.
text/x-vcard attachment: Card for Keith Hopkins
--
To unsubscribe: mail ">majordomo@ale.org with "unsubscribe ale" in message body.