How to create FTP server in Centos? (vsftp)

Create a FTP server in Linux Centos with vsFtp.

1.  Install vsftpd

$ yum install vsftpd

This will install vsftpd server.

2. Configuration:

Open config file  by :

$ vi /etc/vsftpd/vsftpd.conf

a) Disable anonymous login :

anonymous_enable = no

b) Disable user to go out side their assigned directory.

chroot_local_user = yes

3) Restart the ftp  server:

$ service vsftpd restart

4) Make sure it starts on server reboot, so in command line:

$ chkconfig vsftpd on

Creating user and assigning folders to the users for FTP:


a) Create user:

Lets create user with ftpuser as user name, ftppassword as password and assign it to the group ftpgroup  with folder /ftp/ftpuser

$ groupadd ftpgroup

b) Add new user

$ adduser -g ftpgroup -d /ftp/ftpuser ftpuser

passwd ftppassword

c) Set the ownership of user to folder

$ chown ftpuser:ftpgroup /ftp/ftpuser

d) Give read write permission

$ chmod 755 /ftp/ftpuser

e) In /etc/vsftpd/vsftpd.conf  uncomment

local_enable = yes

f) Restart vsftpd

service vsftpd restart

One thought on “How to create FTP server in Centos? (vsftp)

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s