Operating System - HP-UX
1836617 Members
1933 Online
110102 Solutions
New Discussion

Re: ftp a HP/UX directory tree to NT

 
John Hietala_1
Occasional Contributor

ftp a HP/UX directory tree to NT

Can you ftp a directory and all underlying directories in a batch type process. The script would run daily the script needs to ftp all files and directories under on directory to a NT server from a HP/UX system. Files and directories could be added at any time.
3 REPLIES 3
A. Clay Stephenson
Acclaimed Contributor

Re: ftp a HP/UX directory tree to NT

One option is to use ftpcopy.
http://gatekeep.cs.utah.edu/hppd/hpux/Networking/FTP/ftpcopy-0.3.5/man.html

However, if this were me I would script this in Perl using the File::Find module in conjection with the Net::FTP module. The advantage of this method is that error checking is built-in and very easy to implement. If you use typical FTP scripts the question quickly becomes "How do you know everything worked?". Error checking in scripts is far from trivial but is ducksoup using Net::FTP. Yopu could even add code to retry a file up tp n times on a failure. If you search the Forums for "FTP" and "Perl" you should find many examples.
If it ain't broke, I can fix that.
Paul R. Dittrich
Esteemed Contributor

Re: ftp a HP/UX directory tree to NT

How about making a tarball out of the whole thing and then ftp'ing that? WinZIP handles tar files just fine for the NT side.

HTH,
Paul
Chia-Wei
Advisor

Re: ftp a HP/UX directory tree to NT

I would suggest you to tar the directory before using ftp.