Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

When downloading large files (ca. 5GB) with the lftp client, I find that a restart of the FTP service (vsftpd) stops the transfer and I have to restart it from the beginning. Is there a way to prevent the transfer from failing when the FTP server is restarted?

share|improve this question
2  
Not restarting the FTP server isn't an option? –  Daniel Beck Jul 17 '13 at 17:58
    
Expecting a restart of the FTP server not to kill the transfer is expecting too much; I'd suggest that the problem here is that the FTP server gets restarted too often, and that it'd be more worth your time to look for either a way to prevent that from happening, or an alternate file transfer mechanism that's more resilient than FTP. (For example, if the files are also available via HTTP from a service supporting the Range header, you can use a client such as wget which supports restarting partially completed downloads.) –  Aaron Miller Jul 17 '13 at 18:09
add comment

1 Answer

It's not possible as terminating the vsftpd service will also terminate any network connections it has. Even if you could force the client to ignore this, the newly restarted service isn't going to know what to do with fragments of an FTP transfer in progress from a client that hasn't previously logged in to it.

FTP has a facility for resuming interrupted downloads, and vsftpd does support resuming if configured correctly. Looks like the pget -c option in lftp also supports resuming a client transfer.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.