unattended ftp

1998-10-12 Thread Rahul Sood
Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
host and retrieve a file?

-R. Sood
[EMAIL PROTECTED]


Re: unattended ftp

1998-10-12 Thread Ole J. Tetlie
*-Rahul Sood [EMAIL PROTECTED]
|
| Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
| host and retrieve a file?

If you install ncftp, you get a program called ncftpget that can be
used to get files non-interactively (eg in a script).

-- 
...Unix, MS-DOS, and MS Windows (also known as the Good, the Bad,
and the Ugly).   (Matt Welsh)
[EMAIL PROTECTED]   [-: .elOle. :-]   [EMAIL PROTECTED]


Re: unattended ftp

1998-10-12 Thread A. M. Varon
On 12 Oct 1998, Ole J. Tetlie wrote:

 *-Rahul Sood [EMAIL PROTECTED]
 
  Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
  host and retrieve a file?

wget. no shell script necessary to get a file. Handles anonymous and
password protected FTP sites.

regards, 

== == Andre M. Varon  Lasaltech Incorporated
== == Technical Head  Fax-Tel: (034)435-0836
== = ==
==== ==   E-mail  : [EMAIL PROTECTED]
 ==   WebPage : http://andre.lasaltech.com


Re: unattended ftp

1998-10-12 Thread David S. Zelinsky
Rahul Sood [EMAIL PROTECTED] writes:

 Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
 host and retrieve a file?

Some have suggested using ncftp or wget to do this.  That may be the best way
to go.

However, it is also possible to do it with plain-old ftp.  You have to specify
the login and password in a file called `.netrc' in your home directory.  Then
`ftp' to a host listed in that file can be invoked from a script.

See `man ftp' for details.

--
David Zelinsky
[EMAIL PROTECTED]


Re: unattended ftp

1998-10-12 Thread Vincent Murphy
I would definitely recommend wget for this. Excellent utility, with excellent
docs (use info). It'll work through http proxies and everything.

regards,
vinny


Re: unattended ftp

1998-10-12 Thread aqy6633
 | Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
 | host and retrieve a file?
 
 If you install ncftp, you get a program called ncftpget that can be
 used to get files non-interactively (eg in a script).

Not necessaraly with ncftp, plain fto will do. In a script:

#!/bin/sh

ftp -i -n host EOI
user userid passwd
cd /some/dir
bin
get somefile save/file/name
bye
EOI


Alex Y.
-- 
   _ 
 _( )_
( (o___   +---+
 |  _ 7   |Alexander Yukhimets|
  \()|   http://pages.nyu.edu/~aqy6633/  |
  / \ \   +---+


Re: unattended ftp

1998-10-12 Thread Rob Collins
You could write a script like:
/home/foobar/ftp.script:

user foobar foobars_password
lcd /home/foobar
get filename


and then execute it whenyou want, or put it in cron... like this:
/var/spool/cron/crontabs/foobar:

0 0 * * * ftp -n -i /home/foobar/ftp.script



--
quiet rob
---
Just keep telling yourself you are immortal  --Albert Hofmann

On Mon, 12 Oct 1998, A. M. Varon wrote:

 On 12 Oct 1998, Ole J. Tetlie wrote:
 
  *-Rahul Sood [EMAIL PROTECTED]
  
   Excuse if this is a FAQ, but how can I set up a shell script to ftp to a
   host and retrieve a file?
 
 wget. no shell script necessary to get a file. Handles anonymous and
 password protected FTP sites.
 
 regards, 
 
 == == Andre M. Varon  Lasaltech Incorporated
 == == Technical Head  Fax-Tel: (034)435-0836
 == = ==
 ==== ==   E-mail  : [EMAIL PROTECTED]
  ==   WebPage : http://andre.lasaltech.com
 
 
 -- 
 Unsubscribe?  mail -s unsubscribe [EMAIL PROTECTED]  /dev/null