Linux – FTP issue – VSFTPd and connecting to from FileZilla

configurationftplinuxvsftpd

I'm trying to connect to a CentOS Linux box that I have hosted on EC2 and I think I have everything configured correctly but when I try to connect I get this series of messages

Status: Connection established, waiting for welcome message...
Response: 220 (vsFTPd 2.0.5)
Command: USER tyndall
Response: 331 Please specify the password.
Command: PASS *********
Response: 230 Login successful.
Status: Connected
Status: Retrieving directory listing...
Command: PWD
Response: 257 "/home/tyndall"
Command: TYPE I
Response: 200 Switching to Binary mode.
Command: PASV
Error: Connection timed out
Error: Failed to retrieve directory listing

Not sure where to start troubleshooting this issue. Any ideas?
Do I need to change any permissions? I would think this ID has the ability to see my own home directory.

I am able to push/pull files from the command line version of FTP client working on Windows.

Best Answer

I solved this exact problem on one of my servers in the past; It was a Filezilla server on Windows Server 2008 also on EC2.

The solution: It was a matter of setting the passive port range on the ftp server & opening that same range in the EC2 Security Groups. You may even need to add the range to IPTables within CentOS if iptables is being used -- although you should consider turning off iptables as it is a bit redundant with EC2 Security Groups.

Have a look here: http://forum.filezilla-project.org/viewtopic.php?f=6&t=7315

[alt text][1] [1]:http://www.iainlbc.com/wp-content/uploads/2011/01/security_groups.png

You could also configure VSFTPd to use active (not passive) mode - so it uses only port 20/21. The difference between active and passive is explained here: http://www.slacksite.com/other/ftp.html