linux ftp serverLinux serverNETWORK ADMINISTRATIONS

FTP Configurations Secrets in Linux – Step by Step Tutorial

In this video you can learn how to configure the FTP in Linux using the VSFTPD configuration file. I have used the anonymous login to test the ftp login and for the anonymous user the password is none.

To Configure the vsftpd in the Linux Server or in CentOS, you need to perform certain configurations in the linux server. So follow the steps which was given below to configure the ftp server in the CentOS or in any other linux server.

Step 1: Install vsftp Packages

Use the below command to install the vsftpd packages.
yum install vsftpd*
yum install ftp*

Step 2: Configure vsftpd Service

Use the below command to make the vsftpd service to be on at the server startup.
chkconfig vsftpd on

Step 3: Restart vsftpd Services

User the below command to restart the vsftpd services.
service vsftpd restart

Step 4: Configure vsftpd.conf

Enter the following contents in the vsftpd.conf file
anonymous_enable=NO
xferlog_std_format=NO (to get vsftpd log format)
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd/chroot_list
log_ftp_protocol=YES

Step 5: Configure Firewall Rules

Use the below command to setup the firewall rules to allow the port 21 through the linux firewall.
iptables -I INPUT -m state –state NEW -m tcp -p tcp –dport 21 -j ACCEPT
service iptables save

Step 6: Configure Ftp Users & FTP Group

use the below command to add the new users and new groups.
useradd ftpuser
groupadd ftpgrp

Set the Profile Path of the FTP User to the FTP Shared Folder

Profile Path : /ftpshare

Step 7: Configure FTP Shared folder

Use the below command to make and directory and give permissions to the shared folder to the newly created users and groups.
mkdir /ftpshare
chown -R ftpuser:ftpgrp ftpshare/
chmod -R 0770 ftpshare/

Step 8: Add FTP Users to VSFTP
vi /etc/vsftpd/vsftpd.conf
chroot_list_enable=YES

Create a chroot_list file
vi /etc/vsftpd/chroot_list

Add the users in the chroot_list file
#List of Users allowed to access VSFTP
ftpuser
ftpgrp

Step 8: Restart the vsdtpd Services
service vsftpd restart

After configuring all these steps, if the vsftpd server was not working properly or if it didn’t give any response then try to disable the firewall and check. It that too didn’t work then try to disable the SELINUX and try to access the vsftpd server.

source

by TechKENIN

linux ftp server

Leave a Reply

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