Aman Thind wrote: > > As it turned out there was some problem with the file I was trying to > transfer. > I could not transfer it even using an ftp client. > The ftp client also aborts with a time out. > > Another question. > How can I use the *Resume* facility provided by an ftp server??? > Currently on error I restart the process again. > I go back to the start of the script - match the sizes of the file to upload > and the one present - if different then upload - else go to next file. > The incompletely transferred file is overwritten and the transfer is not > resumed from where it aborted.
perldoc Net::FTP [snip] get ( REMOTE_FILE [, LOCAL_FILE [, WHERE]] ) Get `REMOTE_FILE' from the server and store locally. `LOCAL_FILE' may be a filename or a filehandle. If not specified the the file will be stored in the current directory with the same leafname as the remote file. If `WHERE' is given then the first `WHERE' bytes of the file will not be transfered, and the remaining bytes will be appended to the local file if it already exists. So set the third argument of get() to the current size of the file to get the rest of the file. my $remote_file = 'something.zip'; my $local_file = 'something.zip'; my $size = -s $local_file; $ftp->get( $remote_file, $local_file, $size ); John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]