Tyn*_*all 5 linux configuration ftp vsftpd
我正在尝试连接到我在 EC2 上托管的 CentOS Linux 机器,我认为我已经正确配置了所有内容,但是当我尝试连接时,我收到了这一系列消息
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
不确定从哪里开始解决此问题。有任何想法吗?我需要更改任何权限吗?我认为这个 ID 有能力看到我自己的主目录。
我能够从在 Windows 上运行的 FTP 客户端的命令行版本推送/拉取文件。
我过去在我的一台服务器上解决了这个问题;它是 Windows Server 2008 上的 Filezilla 服务器,也在 EC2 上。
解决方案:只需在 ftp 服务器上设置被动端口范围并在 EC2 安全组中打开相同的范围即可。如果正在使用 iptables,您甚至可能需要将范围添加到 CentOS 中的 IPTables - 尽管您应该考虑关闭 iptables,因为它对于 EC2 安全组来说有点多余。
看看这里:http://forum.filezilla-project.org/viewtopic.php?f =6&t=7315
[替代文本][1] [1]:http://www.iainlbc.com/wp-content/uploads/2011/01/security_groups.png
您还可以将 VSFTPd 配置为使用主动(非被动)模式 - 因此它仅使用端口 20/21。主动和被动之间的区别解释如下:http://www.slacksite.com/other/ftp.html