Thanks everyone for your input.
I tried a passive transfer with no luck. Setting Debug=>1 shows that the exchange between my script and the ftp server proceeds normally. The only difference is that only 69,631 of the file's 73,682 bytes are transferred. When I upload the same file manually (via the DOS prompt) the complete file is transferred. Very odd!
I realize we're drifting away from pure perl but any other suggestions would be greatly appreciate.
best,
sz | [reply] |
This is the part where I admit to an embarrassing oversight.
I finally traced the bug to a subtle buffering problem. The file being uploaded is not fully written at the time that it is ftp'ed. I never noticed because by the time the ftp is completed and I check the local copy of the file, the buffer has been written to disk. Once I explicitly close (FH) prior to uploading the file, my problem goes away.
On the bright side, I learned a lot more about Net::ftp.
Thanks again everyone!
sz
| [reply] [d/l] |