The most effective way - VSFTP startup failure - Failed to start Vsftpd ftp daemon

Keywords: vsftpd ftp vsftp firewall

VSFTP startup failure - Failed to start Vsftpd ftp daemon

The error is as follows

[root@host-liu vsftpd]# systemctl status vsftpd.service
vsftpd.service - Vsftpd ftp daemon
   Loaded: loaded (/usr/lib/systemd/system/vsftpd.service; disabled)
   Active: failed (Result: exit-code) since Tue 2018-07-03 10:09:23 CST; 2min 3s ago
  Process: 2600 ExecStart=/usr/sbin/vsftpd /etc/vsftpd/vsftpd.conf (code=exited, status=2)

Jul 03 10:09:23 host-liu systemd[1]: vsftpd.service: control process exited, code=exited status=2
Jul 03 10:09:23 host-liu systemd[1]: Failed to start Vsftpd ftp daemon.
Jul 03 10:09:23 host-liu systemd[1]: Unit vsftpd.service entered failed state.

Analysis cause

  1. Some people say listen is changed to NO, but my configuration file is already NO, so this method is not feasible.
  2. Some people say that the port occupancy problem, look at the port, 21-20 are not service occupancy, can only think of other ways,
  3. Close the firewall and SELinux to test best, excluding other interference factors.

Solution

  1. Generally, boot errors must be a configuration file problem, which occurred when I was configuring virtual user mode.
  2. Finally, empty all configuration files, and then vi line by line input, restart the service, found that it can be used, perhaps when they copy and paste online code, the coding format problems caused.
  3. If you have this problem, you can try to empty the configuration file, and then add the following simplest configuration file parameters one line to test.

The simplest configuration file

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
listen=NO
listen_ipv6=YES
pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES

Virtual User Profile

anonymous_enable=NO
local_enable=YES
guest_enable=YES
guest_username=virtual
allow_writeable_chroot=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
xferlog_enable=YES
connect_from_port_20=YES
xferlog_std_format=YES
listen=NO
listen_ipv6=YES
pam_service_name=vsftpd.vu
userlist_enable=YES
tcp_wrappers=YES
user_config_dir=/etc/vsftpd/vuser_dir
~                                     

Posted by martyn on Mon, 04 Feb 2019 22:42:16 -0800