July 2, 2024
Tutorials

How to Install FTP Server on Ubuntu 22.04

How to install ftp server on ubuntu 22

FTP is the short form of File Transfer Protocol. FTP server is a software that enables you to send and receive files through the internet. It is easy to operate as well as provides a convenient way to transfer files securely.

In short, setting up the FTP server on Ubuntu 22.04 facilitates you to transfer data in more secure and effective way.

This detailed guide explains the process of installing the FTP server on Ubuntu 22.04 system. We will demonstrate the following topics:

  • How to Install the FTP Server on Ubuntu 22.04 system?
  • How to Configure the FTP Server on Ubuntu 22.04 system?
  • How to Establish a Connection with FTP Server?

How to Install the FTP Server on Ubuntu 22.04 System?

The following guidelines will present you with the Installation process of the FTP server on a Linux-based system including Ubuntu 22.4.

Step 1: Update Ubuntu Repository

This step is important for keeping your system’s package list up to date on Ubuntu 22.04:

sudo apt update

Updating your Ubuntu system ensures that you will be able to install the newest versions of software from Ubuntu’s repositories.

Step 2: Install FTP Server

To set up the FTP server on your Ubuntu system, you need to install the “vsftpd” package using the command:

sudo apt install vsftpd

Upon executing this command, you will find that it installed the “vsftpd” package file along with its dependencies.

Step 3: Confirm FTP Server Installation

To confirm that the installation was successful, verify the “vsftpd” version:

vsftpd -v

The version of vsftpd (i.e. 3.0.5) confirms the successful installation of the FTP server.

Step 4: Start FTP Service

To utilize the “vsftpd” service, you need to start it by using the command:

sudo systemctl start vsftpd

You will see no output if the command executes successfully.

Step 5: Enable FTP Service

Through the following command, enable the “vsftpd” service to ensure that it starts automatically during system boot:

sudo systemctl enable vsftpd

The “vsftpd” service is now enabled on your Ubuntu 22.04 system. Now, you don’t need to start it manually after your system restarts.

Step 6: Check FTP Service Status

To verify that the “vsftpd” service is running correctly, you can use the command:

sudo systemctl status vsftpd

The “vsftpd” service is now up and running without any errors.

How to Configure the FTP Server on Ubuntu 22.04 System?

The FTP server can be configured on your Ubuntu 22.04 machine through this easy-to-use process.

Step 1: Update FTP Configuration File

To modify the FTP configuration file according to your requirements, you have to access the “vsftpd.conf” file:

sudo nano /etc/vsftpd.conf

Within this configuration file, the highlighted lines should be modified per the requirements:

Step 2: Restart FTP Service

After making the necessary modifications to the “vsftpd” configuration, apply them by restarting the FTP service:

sudo systemctl restart vsftpd.service

This command will refresh and update the modified configuration file.

Step 3: Enable Firewall

Enable the firewall to allow the FTP traffic:

sudo ufw enable

In response to the command, you will see the message that the Firewall is now active on your Ubuntu 22.04 machine.

Step 4: Allow the FTP Server Traffic

Once the Firewall is activated and enabled, allow the FTP server traffic via the Firewall to enable communication with the FTP server:

sudo ufw allow ftp

Step 5: Check Firewall Status

After configuration, use the command to view the current status of the Firewall:

sudo ufw status

Make sure that ufw status is “Active” on your Ubuntu 22.04 machine.

How to Establish a Connection with FTP Server?

These few steps will guide you to establish a connection with the FTP server on your Ubuntu 22.04 system.

Step 1: Find the IP address

Find the IP address of the server you want to connect to the FTP server:

ip address

As highlighted in the above screenshot, you will need these details to establish a connection through the FTP server.

Step 2: Connect to FTP Server via IP Address

Upon completing the above procedure, let’s connect to the FTP server:

ftp 192.168.102.213

This command successfully initiated the FTP session after prompting you to enter your username (linux) and password to authenticate.

Now, you are in the FTP session. Use the “ls” command to inspect the directories and files within the remote path:

ls

Here, you can view the list of available files and folders in the remote path.

Step 3: Exit the FTP Connection

To terminate the FTP session, use the “exit” command to return to the command prompt:

exit

Through this post, you have explored the installation process of the FTP server, configuration, and connection to the remote system.

Conclusion

One can Install the FTP server on the Ubuntu 22.04 system through a simple process. Begin the setup process with the command “sudo apt install vsftpd”. After installing the FTP package, make necessary modifications as per your needs, and then, use the “ftp <ip_address> in the terminal to connect to the remote system.

Leave feedback about this

  • Quality
  • Price
  • Service

PROS

+
Add Field

CONS

+
Add Field
Choose Image
Choose Video