Skip to content
Related Articles

Related Articles

Improve Article
How to Change FTP Port in Linux?
  • Last Updated : 24 Feb, 2021

Files are either uploaded or downloaded to the FTP server. The files are moved from a personal computer to the server when you upload files. The files are moved from the cloud to your personal computer when the files are downloaded. In order to transfer files through FTP, TCP/IP (Transmission Control Protocol/Internet Protocol), or the language used by the internet to execute commands, is used.

To adjust the default Linux port of the Proftpd operation, first, open the Proftpd main configuration file for editing with your favorite text editor by issuing the command below.

Step 1: First open Proftpd main configuration file for editing.

$ nano /etc/proftpd/proftpd.conf
How to Change FTP Port in Linux

Open config file

Step 2: Find the following line port number.

Port 21
How to Change FTP Port in Linux

Find Port

Step 3: And change the FTP default port 21 to a custom port, for example, 210.



How to Change FTP Port in Linux

Change the port

Step 4: Save and close the file. To take effect the changes, restart the proftpd service using the below command

$ systemctl restart proftpd
How to Change FTP Port in Linux

Restart Proftpd service

Step 5: Check the table of local network sockets with the netstat or ss command.

$ netstat -tlpn| grep nginx
OR
$ ss -tlpn| grep nginx
How to Change FTP Port in Linux

Check port

Now your FTP port should be changed.

My Personal Notes arrow_drop_up
Recommended Articles
Page :