How To Create FTP Accounts In Centos Server
Description:
In Apache web server to access the folders from local system FTP accounts needed.Default sftp account is available but it is for accessing complete server from the FTP client.Here is article to create FTP accounts to the particular folder.
Steps:
Before create FTP accounts need to install vsftpd in server.
– Install vsftpd in the server.
$yum install vsftpd
– Need to install ftp client in the server to connect from the locations.
$yum install ftp
– Now configure vsftpd configuration file.Update the below settings,
$nano /etc/vsftpd/vsftpd.conf
anonymous_enable=NO
local_enable=YES
write_enable=YES
connect_from_port_20=NO
chroot_local_user=YES
local_umask=022
– Create a user and assign to the directory,
$useradd -d /var/www/html -s /sbin/nologin test
$passwd test
– Add user to ftpaccounts,
$ /usr/sbin/groupadd ftpaccounts
$ usermod -G ftpusers test
– Assign the user perimission and change the ownership,
$chown -R test /var/www/html
$chmod 775 /var/www/html
– Create a userlist and add the ftp user,
$nano /etc/vsftpd/vsftpd.userlist
– Restart the FTP services,
$service vsftpd start
– To test the FTP follow the below steps,
$ftp localhost
– For remote test follow the below commands,
$ftp serverip
$ Name (your.ftp.server.com:yourname):
Name (localhost:root): ftpuser
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
Tags:ftp,FTP user,FTP client,FTP client configuration,FTP issue,FTP user creation,vsftpd,Sftp,centos ,centos configuration,mail exchanger,local exchanger
Add Comment