CONFIGURE NEW FTP USER ON CENTOS 7

update yum repo

$ sudo yum update

install ftp

$ sudo yum install vsftpd
$ sudo vi /etc/vsftpd/vsftpd.conf

anonymous_enable=NO
ascii_upload_enable=YES
ascii_download_enable=YES
write_enable=NO
local_enable=YES
chroot_local_user=YES
ftpd_banner=Welcome to blah FTP service.

$ sudo systemctl restart vsftp
$ sudo systemctl enable vsftpd
$ sudo firewall-cmd –permanent –add-port=21/tcp
$ sudo firewall-cmd –permanent –add-service=ftp
$ sudo firewall-cmd –reload

 

$ sudo yum provides \*/bin/ftp

add new user

$ sudo useradd musti
$ sudo passwd musti
Changing password for user musti.
New password: blabla
Retype new password: blabla

allow user to access home directory

$ sudo setsebool -P ftp_home_dir on

TEST FTP ACCOUNT:

use any ftp client such as Filezilla

(whatever your ip is)
Host: 10.10.x.x
username: musti
password: blabla
Port: 21
Advertisements

Leave a Reply

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

WordPress.com Logo

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

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s