How to Install and Configure ftp server in centos 7/8 , redhat 7/8 , fedora

Share on :

How to Install and configure FTP server in centos 7,8 / RedHat 7,8 / Fedora (Anonymous) :-

FTP stands for file transfer protocol and it is used to share files from one computer to another it computer. basically, it is based on the client-server model. It can be integrated with apache server or HTTP server to upload website files to the server. In this blog, we will create an anonymous ftp server using vsftpd package in centos 7,8 / RedHat 7,8 /Fedora.

1) Install the VsFtp (Very Secure File Tranfer Protocol) Package :-

——< for Centos 7,8 / Rhel 7,8 >——
yum install vsftpd -y
——-< Fedora >——
dnf install vsftpd -y

2) Start and Enable the Service.

systemctl start vsftpd
systemctl enable vsftpd

3) Apply firewall rule

firewall-cmd –permanent –add-service=ftp
firewall-cmd –reload

4)Open your WebBrowser.


Now you start uploading the files that you want to share by ftp in /var/ftp/ directory.
after you upload your file make sure you update the SELinux context on the uploaded files as In Redhat, Centos, Fedora by default SELinux is enforcing the SELinux context of ftp files is “public_content_t”. you can just run the following command to update the context on the uploaded files.

restorecon -vvRF /var/ftp

We have configured FTP server successfully.

Now, let’s move to client side.

FTP Clients:-

The Clients in the server network can access the FTP server just by opening their web server and searching ftp://<server_ip>

or the Clients can even access it by cli (terminal) by installing ftp client package.

——< for Centos 7,8 / Rhel 7,8 >——
yum install ftp -y
——-< Fedora >——
dnf install ftp -y
After we install the ftp client package we can access the ftp server by terminal.
Connected to (
220 (vsFTPd 3.0.2)
Name ( anonymous
331 Please specify the password.
Password:just press enter
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
227 Entering Passive Mode (192,168,122,154,189,155).
150 Here comes the directory listing.
drwxr-xr-x 2 0 0 6 Aug 03 2017 pub
226 Directory send OK.

Watch our Youtube Video for more detailed Explanation

Share on :