How To Install A VSFTPD FTP Server On CentOS 7
How To Install A VSFTPD FTP Server On CentOS 7
FTP stands for File Transfer Protocol. It has been a standard method for transferring files between computers for decades. FTP is by nature an insecure method for transferring files. This guide will show you how to configure and Install A VSFTPD FTP Server On CentOS 7.
1. Install VSFTPD software with the following command:
[root@zabbixserver ~]# yum install vsftpd -y
2. Start the service and set it to launch when the system boots with the following:
systemctl start vsftpd
systemctl enable vsftpd
3. Configure VSFTPD
The configuration file is /etc/vsftpd/vsftpd.conf .
4. Edit the configuration file with the following command:
[root@zabbixserver ~]# vi /etc/vsftpd/vsftpd.conf
5. Set your FTP server to disable anonymous users and allow local users.
Find the following entries in the configuration file, and edit them as given below:
anonymous_enable=NO
local_enable=YES
Allow a logged-in user to upload files to your FTP server:
write_enable=YES
chroot_local_user=YES
allow_writeable_chroot=YES
userlist_enable=YES
userlist_file=/etc/vsftpd/user_list
userlist_deny=NO
userlist_deny allow users if set to "NO", If its set to yes it will lock all the users List in the file.userlist_file=/etc/vsftpd/user_list
userlist_deny=NO
8. Now Start the vsftpd service.
#systemctl restart vsftpd
Create FTP User:
To create a new FTP user do the following:
#adduser testuser
#passwd testuser
echo testuser | tee –a /etc/vsftpd/user_list
# mkdir -p /home/testuser/ftp/upload
# chmod 550 /home/testuser/ftp
# chmod 750 /home/testuser/ftp/upload
# chown -R testuser:testuser /home/testuser/ftp
8. Now restart the vsftpd service.
[root@zabbixserver ~]# systemctl restart vsftpd
9. Now we are all set to test our FTP server.
If you Get error Like ftp command not found, Please intall ftp client:
[root@zabbixserver ~]# yum install ftp
[root@zabbixserver ~]# ftp 192.168.1.103
No comments