[SunHELP] Script to automate ftp.

Will Mc Donald sunhelp at sunhelp.org
Tue Sep 18 03:46:19 CDT 2001


I don't think a .netrc file will allow you to do this unless you know the
directory structure in advance. I believe the ncftp client will let you do
this in a macro/scriptable way but for the life of me I can't find it in the
bloody documentation.

http://www.ncftp.com/ncftp/

I know you can use -R for the whole directory tree but I can't find the
macro reference.

Will.

----- Original Message -----
From: <Swamy_CNN at satyam-infoway.com>
To: <sunhelp at sunhelp.org>
Sent: Monday, September 17, 2001 8:24 AM
Subject: Re: [SunHELP] Script to automate ftp.


> Hi all,
>
>      I was trying ftp automation some time back. But in my case i wanted
to
> Download the directories recursilvey. But i was unsuccesfull, wanted to
know if
> any of u tried this
>
> Regds,
> swamy c.n.n
>
> ---------------------------
> Andrew,
> You can write a script, then schedule the script using cron.
> Below is the sample script:
>
> cd <destination dir>
> ftp -n -v > ftp.log << EOF
> open <host name or ip-address>
> user username password
> cd <source dir>
> bin (if you are trying to get binary files)
> get <filename>
> quit
> EOF
>
>
> _______________________________________________
> SunHELP maillist  -  SunHELP at sunhelp.org
> http://www.sunhelp.org/mailman/listinfo/sunhelp




More information about the SunHELP mailing list