2

I'm using a GUI FTP client (WinSCP) to connect the remote FTP server (which is powered by vsftpd on Cent OS).

The GUI logs show that I can connect to the server but it was stucking on retrieving directory listing... and finally timeout!

enter image description here

enter image description here

Also I'm following an answer to vsftpd error Listing Directories and have configured my vsftpd.conf, but still failed.

Anybody some clues?

vsftpd.conf sample:

dirlist_enable=YES
hide_file=no

ftp_data_port=20
listen_port=21

pasv_enable=YES
pasv_min_port=64000
pasv_max_port=64321
port_enable=YES

pasv_address=1**.**.**.**
pasv_addr_resolve=YES

local_root=/var/ftp/pub
Sam Su
  • 139
  • 1
  • 1
  • 4

2 Answers2

6

You have to open the port range 64000–64321 in the local firewall on the server. And if there are any external firewalls or NAT's, configure these to allow/route the port range too.

See also a relevant WinSCP article to understand, what network configuration is needed for the passive FTP.

Martin Prikryl
  • 7,756
  • 2
  • 39
  • 73
1
  • Check your VSFTPD logs and take appropriate action.
  • If SELinux is enabled check /var/log/audit.audit.log for relevant messages and take appropriate action.
  • Ensure that your firewall is configured to allow port 21 and RELATED connections.
user9517
  • 115,471
  • 20
  • 215
  • 297