OS: CentOS 7 with VSFTPD with firewall turned off for the moment
VSFTPD Configuration Settings:
[root@Turbo ~]# vi /etc/vsftpd/vsftpd.conf
anonymous_enable=NO local_enable=YES write_enable=YES local_umask=022 dirmessage_enable=YES xferlog_enable=YES connect_from_port_20=YES xferlog_std_format=YES ftpd_banner=Welcome to the DataMover FTP service. chroot_local_user=YES local_root=/home/ftp-docs listen=YES listen_ipv6=NO pasv_enable=YES pasv_max_port=65534 pasv_min_port=1024 pasv_address=192.168.20.88 hide_file=NO pam_service_name=vsftpd userlist_enable=YES tcp_wrappers=YES
Logon Type Normal Port 21 Server Type Default (tried UNIX) Transfer Mode Passive (tried Active) Charset Auto detect Encryption Only use plain FTP (insecure)
I tried all combinations of transfer mode and server type (between UNIX and auto detect) to no avail. I used plain FTP, as I did not add TLS to my CentOS machine. I had that protocol for a while, as I do not have it, I just wasted time negotiating down to plain FTP.
Here is the Filezilla output:
Status: Disconnected from server Status: Connecting to 192.168.20.88:21... Status: Connection established, waiting for welcome message... Status: Connected Status: Retrieving directory listing... Status: Directory listing of "/" successful
What is interesting is that I do not see the welcome banner. I half expected to see that, as the Filezilla log says "waiting for welcome message...".
Like the welcome message, the contents of the directory are blank.
The user is fine. I logged in as the user and did a
cd ~ and was able to verify that I went to the
The log files show major nothingness.
Dec 11 09:23:35 Turbo systemd: Reloading. Dec 11 09:23:35 Turbo systemd: [/usr/lib/systemd/system/lvm2-lvmetad.socket:9] Unknown lvalue 'RemoveOnStop' in section 'Socket' Dec 11 09:23:35 Turbo systemd: [/usr/lib/systemd/system/dm-event.socket:10] Unknown lvalue 'RemoveOnStop' in section 'Socket' Dec 11 09:23:36 Turbo avahi-daemon: Invalid response packet from host 192.168.20.74. Dec 11 09:23:37 Turbo avahi-daemon: Invalid response packet from host 192.168.20.74. Dec 11 09:23:37 Turbo avahi-daemon: Invalid response packet from host 192.168.20.74. Dec 11 09:23:40 Turbo systemd: Stopping Vsftpd ftp daemon... Dec 11 09:23:40 Turbo systemd: Stopped Vsftpd ftp daemon. Dec 11 09:23:45 Turbo systemd: Starting Vsftpd ftp daemon... Dec 11 09:23:45 Turbo systemd: Started Vsftpd ftp daemon.
With all my testing today, the /var/log/xferlog, shows emptiness.
Tue Dec 8 15:48:35 2015 1 ::ffff:192.168.20.74 0 /CreativeCloudSet-Up.exe b _ i r datamover ftp 0 * i ~
My command line on the server is fine too.
[root@Turbo ~]# systemctl daemon-reload [root@Turbo ~]# systemctl stop vsftpd [root@Turbo ~]# systemctl start vsftpd [root@Turbo ~]# vi /var/log/messages [root@Turbo ~]# vi /var/log/xferlog [root@Turbo ~]#
Just for completeness sake, the contents of the home directory are fine.
[root@Turbo ~]# ls -l /home total 4 drwxr-xr-x. 3 root ftp-users 35 Dec 9 16:29 ftp-docs ... [root@Turbo ~]# [root@Turbo ~]# cd /home/ftp-docs/ [root@Turbo ftp-docs]# ls -l total 4 -rwxr--r--. 1 datamover root 13 Dec 8 15:47 smurfit.txt drwxr--r--. 2 root root 6 Dec 9 16:29 sub1 [root@Turbo ftp-docs]#
I perused quite a few webpages, which is why I added
hide_file and the four passive entries into my
vsftpd.conf configuration file. Other people had a problem connecting. That is and was not my problem. I connect fine. I just do not see anything.
Although I have firewall disabled at the moment, here is my
# FTP -A INPUT -m state --state NEW -m tcp -p tcp --dport 20 -j ACCEPT -A INPUT -m state --state NEW -m tcp -p tcp --dport 21 -j ACCEPT -A INPUT -m state --state NEW -m tcp -p tcp --dport 1024:65535 -j ACCEPT
I did read that CentOS 7 uses FirewallD, not iptables, but as you can see:
[root@Turbo ~]# firewall-cmd --get-active-zones FirewallD is not running [root@Turbo ~]#
Here are some of the resources that I perused:
- FTP FileZilla
- No route to host
- Configure vsftpd to work with passive mode
- VSFTPD does not list content of a directory (my problem)
- How to install and configure VSFTPD on CentOS 7
- Setting VSFTPD to allow user upload
- Set default ftp root folder
- Dir list not visible
- VSFTPD to jail a user
Any thoughts on anything that I missed?