When connecting to a ftp via terminal, everthing is fine.

When using lftp instead, I'm constantly getting timed out and can never sync the folder content. But why?


lftp -c "
open $HOST
user $USER $PASS
mirror --delete --verbose $FSOURCE $FTARGET

Result: login is successful, but then getting an info about incorrect PASV mode, then then nothing ever happens.

<--- 230 User <username> logged in
---> PWD
<--- 257 "/" is the current directory
---> PBSZ 0
<--- 200 PBSZ 0 successful
---> PROT P
<--- 200 Protection set to Private
---> PASV
<--- 227 Entering Passive Mode (...).
---- Address returned by PASV seemed to be incorrect and has been fixed
---- Connecting data socket to (...) port 65242

I also tried set ftp:passive-mode false to force active mode. Result:

---> PORT ...
<--- 500 Illegal PORT command
---- Switching passive mode on
---> LIST
---> ABOR
---- Closing aborted data socket
---- Closing control socket

It turned out normal ftp command via terminal was still successful. I could fix lftp preventing the use of ssl. Probably the ftp owner disabled this suddenly.

set ftp:ssl-allow off;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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