Home > Article > System Tutorial > Specific method to install vsftpd on Centos7
yum install -y vsftpd
vi /etc/vsftpd/vsftpd.conf
Modify the configuration file as follows:
anonymous_enable=NO
local_enable=YES
When chroot_list_enable=YES, chroot_local_user=YES, users listed in the /etc/vsftpd.chroot_list file can switch to other directories; users not listed in the file cannot switch to other directories.
chroot_local_user=YES chroot_list_enable=YES chroot_list_file=/etc/vsftpd/chroot_list
Add
at the end of the configuration fileallow_writeable_chroot=YES
Otherwise an error will be reported
500 OOPS: vsftpd: refusing to run with writable root inside chroot()
If /etc/vsftpd/chroot_list does not exist, you need to create this file
vi /etc/vsftpd/chroot_list
:wq Just save and exit.
ascii_upload_enable=YES ascii_download_enable=YES
Finally: wq save changes and restart vsftpd
systemctl restart vsftpd.service
useradd -d /var/ftp/public_root -g ftp -s /sbin/nologin ftpuser
Change the FTP user password
passwd ftpuser
The above is the detailed content of Specific method to install vsftpd on Centos7. For more information, please follow other related articles on the PHP Chinese website!