Hi
Several differing responses to my question:
" I'm setting up a job to run regular unattended file transfers using ftp.
Setting up the job is not a problem and im sending the ftp output into a log
file but can't decide the best way to check whether the job has actually worked.
I am not looking to check whether ftp itself ran but want to guard against a
failed login or failed put of the files concerned."
The responses are summarised below
1. A few people pointed out tools available from the Web to provide enhanced ftp
like capabilities including the ability to check the status of a particular
operation within ftp:
nctfp
http://www.ncftp.com/ncftp/.
wget
ftp://gnjilux.cc.fer.hr/pub/unix/util/wget/
mirror
http://sunsite.org.uk/packages/mirror/
2. Use Secure Shell (ssh) - Again better ftp status checking
3 Use PERL and the NET:Ftp module - As above
4. Check the log file and look for the success message
i.e
grep -q "226 Transfer complete." ftplogfile
sentok=$?
if (( $sentok == 0 ))
then
echo "Successful xfer of $file"
fi
I decided to go with option 4 because I was already thinking along these lines
and did not want to intoduce any new software to the platform. However I shall
make a note of the downloads mentioned in option 1 because they may well come
in handy in the future.
Thanks to all who responed
Dave
Received on Fri Jul 14 2000 - 08:30:54 NZST