Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

In a vsftpd server enviroment, shared various directories from nfs mountpoints, I can log in without problem, but when I send the first "ls", the vsftp give me the directory listing:

lftp user1@10.10.10.10:~> ls
-rw-rw-rw-    1 1160     1016          392 Jun 06 09:28 test.gif

but not give me the shell again (lftp client). In the server log I can see that the last message is:

"150 Here comes the directory listing."

Why does this happen?

share|improve this question
add comment

2 Answers

Check your firewall settings, chances are you are not allowing the PASV ports through, or maybe port 20 ftp-data. Try opening TCP ports 50000-55000 on your firewall and add the below to your vsftpd.conf.

pasv_min_port=50000
pasv_max_port=55000

If using active mode then you should just need port 20, if using passive then you should be setting those ports on your firewall and the matching in the ftp config.

Here is a quick overview on Active vs Passive http://slacksite.com/other/ftp.html

share|improve this answer
add comment

I had that same problem on my Amazon EC2 Ubuntu machine. I had ports 50000-51000 set for the passive mode in vsftpd.conf, and I had to open the ports on the security group AWS firewall settings.

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.