1753713 Members
4614 Online
108799 Solutions
New Discussion юеВ

Re: Need FTP scripts

 
SOLVED
Go to solution
Steven Schweda
Honored Contributor

Re: Need FTP scripts

Is FTP the only way you can access the
destination server? With rsh (or ssh), it's
normally possible to construct a "tar"
pipeline (with or without compression), and
do the job with no need for temporary disk space.

Wget (-r) can be useful, but you'd need to
run it on the destination system. (And if
you can do that, you could probably use the
rsh + "tar" pipeline method.)

> [...] Tried to ftp, but it is not sending
> directories. [...]

A typical FTP client does what you tell it to
do. I have not seen one which can read
minds.

> Please help me with scripts to automate the
> ftp.

That's not the easy way.
macosta
Trusted Contributor

Re: Need FTP scripts

Also, if FTP is a hard requirement, and you have ksh installed, try hardfeed:
http://www.unix.com/shell-programming-scripting/9174-recursive-ftp-here-last.html
Mark Ellzey
Valued Contributor

Re: Need FTP scripts

Vthiru,

Why not use NFS? You could mount a filesystem from your ftp server and use standard cp/tar/cpio utilities to move the data. You also wouldn't be subject to ftp's one-file-at-a-time limitation.

Regards,
Mark
Steven Schweda
Honored Contributor

Re: Need FTP scripts

> Why not use NFS? [...]

Lack of administrative access on one system
or the other?

Many things are possible. Some are easier
than others. Without more information on the
environment and its limitations, it's tough
to do more than guess at an optimal solution.

I normally assume that a questioner who, in
the face of repeated requests, fails to
supply an adequate explanation of the
problem, probably doesn't really care much
about getting a useful answer.