[SunHELP] Script to automate ftp.

Magnus Abrante sunhelp at sunhelp.org
Tue Sep 18 09:20:18 CDT 2001


Expect is a good thing in this case, as far as i remember it even
comes with a script for automating ftp..

If the only thing you want to do is to download files wget would
be a good alternative as well... 

Not sure if its mentioned already :)

Best regards,

        //Magnus Abrante
/* This is my opinion and not the one of my employer */


> You could also use Expect.  That's kind of what it's made for...
> John
> 
> 
> Swamy_CNN at satyam-infoway.com wrote:
> > 
> >                                               Placed At :
> > 
> > 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
> _______________________________________________
> SunHELP maillist  -  SunHELP at sunhelp.org
> http://www.sunhelp.org/mailman/listinfo/sunhelp



More information about the SunHELP mailing list