in reply to Perl Net::FTP put() gives little help on errors
I've also found Net::FTP put() unreliable at times. When it fails unexpectedly the message isn't always accurate as you've found, often it contains the message of a previous ftp action which makes it totally useless.
My work around is to:
(a) check the result of put()
(b) if it fails, close the ftp session, and open it again
(c) put() the file again
(d) repeat from (a) as many times as you can stand to wait (usually the second time works)
I've found it doesn't do any good to try resending the file without closing and opening the ftp session first.
|
|---|