sudo apt-get install vsftpd
The FTP configuration file is
/etc/vsftpd.conf
You can use the following command to open, close, and restart the FTP service
sudo /etc/init.d/vsftpd startsudo /etc/init.d/vsftpd stopsudo /etc/init.d/vsftpd restart
You can see that there are more FTP user groups and FTP users in the system using the following commands
cat /etc/groupcat /etc/passwd
The directory location of the FTP server is in/srv/ftp, which is also the root directory when anonymous users visit.
This indicates that the FTP service is turned on, but Anonymous logon is not turned on.
Configure vsftpd.conf
Edit/etc/vsftpd.conf File:
// 允许匿名用户登录anonymous_enable=YES// 允许本地用户登录local_enable=YES// 开启全局上传write_enable=YES// 允许匿名用户上传文件anon_upload_enable=YES // 充许匿名用户新建文件夹anon_mkdir_write_enable=YES
Anonymous User Login
Create a pub for anonymous users to upload files under/srv/ftp and change their permissions
cd /srv/ftpsudo mkdir pubsudo chown ftp:ftp pub
Ubuntu 16.04 Install VSFTPD and turn on FTP service