How to install vsftpd on centos 7
I feel very bad. I have tested none of them on the Internet, but I have always reported errors.
After 10 reinstalls, the correct method is finally tested.
# Official website configuration instructions ##
Https://security.appspot.com/vsftpd/vsftpd_conf.html
# Requirements ##
1) only the current user can be seen during FTP login and cannot be redirected to the main directory.
2) prohibit anonymous users from logging on to FTP
3) modify the FTP listening port number!
# Problem ##
Yum install vsftpd
There are a lot of problems with the results,
1) unable to start systemctl stop vsftpd --> succeeded. The second line of systemctl start vsftpd ==> always reports an error
[root@niche vsftpd]# whereis vsftpdvsftpd: /usr/sbin/vsftpd /etc/vsftpd /usr/share/man/man8/vsftpd.8.gz[root@niche vsftpd]# systemctl status vsftpdvsftpd.service - Vsftpd ftp daemon Loaded: loaded (/usr/lib/systemd/system/vsftpd.service; disabled) Active: failed (Result: exit-code) since Wed 2014-12-17 15:16:58 UTC; 18min a goDec 17 15:16:58 niche systemd[1]: vsftpd.service: control process exited, c...=2Dec 17 15:16:58 niche systemd[1]: Failed to start Vsftpd ftp daemon.Dec 17 15:16:58 niche systemd[1]: Unit vsftpd.service entered failed state.Dec 17 15:17:25 niche systemd[1]: Stopped Vsftpd ftp daemon.Dec 17 15:23:12 niche systemd[1]: Stopped Vsftpd ftp daemon.Dec 17 15:26:11 niche systemd[1]: Stopped Vsftpd ftp daemon.Dec 17 15:33:55 niche systemd[1]: Stopped Vsftpd ftp daemon.Dec 17 15:34:11 niche systemd[1]: Stopped Vsftpd ftp daemon.Hint: Some lines were ellipsized, use -l to show in full.[root@niche vsftpd]# systemctl stop vsftpd[root@niche vsftpd]# systemctl start vsftpdJob for vsftpd.service failed. See 'systemctl status vsftpd.service' and 'journalctl -xn' for details.[root@niche vsftpd]#
The final solution is to manually kill the process. Ps auxf | grep vsftpd.
Then restart systemctl start vsftpd, and you can use systemctl to control vsftpd. Is there a ghost?
2) Disable anonymous users. vsftpd. conf was modified from the beginning, but it cannot be restarted. You can only manually kill the process.
3) locking in the root directory prevents local users from jumping out of the root directory. The last line can be tested many times:
Chroot_local_user = NO
Chroot_list_enable = YES
# (Default follows)
Chroot_list_file =/etc/vsftpd/chroot_list
4) modify the listening port number: add the new port number at the end of the configuration file, listen_port = 801, and then restart! (By default.fu@foxmail.com)