HostOnNet Blog

Install vsftpd on CentOS

Looking for Linux Server Admin or WordPress Expert? We can help.

vsftpd is an FTP server. To install vsftp on CentOS, run

yum -y install vsftpd

Make it start on boot with

chkconfig vsftpd on

Start FTP Server with

service vsftpd start

Now system users will be able to login, lets create a user, set it a password.

useradd -m ftpuser
passwd ftpuser

Exmaple

[root@localhost ~]# useradd -m ftpuser
[root@localhost ~]# passwd ftpuser
Changing password for user ftpuser.
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.
[root@localhost ~]# 

Now you will be able to use this user and password to login to FTP user.

chroot

By default FTP user will be able to navigate to any folder. This is not desirable if you have more users on the server. To avoid this, we can enable chroot.

Edit vsftpd.conf file

vi /etc/vsftpd/vsftpd.conf

In the file, add

chroot_local_user=YES

Restart vsftpd.

service vsftpd restart

Posted in CentOS

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.