1833609 Members
4239 Online
110062 Solutions
New Discussion

ftp recursive?

 
Pat Conrad
Occasional Contributor

ftp recursive?

Is there a way to use ftp recursively to ftp directorite & subdirectories?
5 REPLIES 5
John Bolene
Honored Contributor

Re: ftp recursive?

You can turn prompt off by (prompt) and then use the mget or mput command. This will transfer all the files in a directory. Binary mode is deafult, you may want to set ascii mode if they are all ascii files.

If you want all files in subdirectories, you will need to tar up the bunch of them and ftp that over.
It is always a good day when you are launching rockets! http://tripolioklahoma.org, Mostly Missiles http://mostlymissiles.com
A. Clay Stephenson
Acclaimed Contributor

Re: ftp recursive?

Hi Pat:

There is no easy way to do this with standard
ftp but you can do it with 'ftpcopy' available from:
http://hpux.cs.utah.edu/hppd/hpux/Networking/FTP/ftpcopy-0.3.5/

The other way (and really the easist to script or run interactively) is rcp which has an option -r for recursive copies. Man rcp for details.

Clay
If it ain't broke, I can fix that.
someone_4
Honored Contributor

Re: ftp recursive?

If your systems are tusted you can do
rcp -p -r root@hotname:/dir/of/data/you/want /dir/you/want/data/at/on/hostname

Richard
someone_4
Honored Contributor

Re: ftp recursive?

there needs to be a space between the path of the data you want and path of were you want to put it.
rcp -p -r root@hotname:/dir/of/data/you/want /dir/you/want/data/at/on/hostname

Richard
Uday_S_Ankolekar
Honored Contributor

Re: ftp recursive?

Hi
on ftp prompt use "prom off" and the use mget or mput.. Or lese best way is use rcp command. But you need to modify .rhost file for this.

--USA--
Good Luck..