How to change pure-ftpd port
pure-ftpd by default listens on port 21. We will change the FTP port from 21 to some other port. This instruction work for RHEL, CentOS, AlmaLinux, Oracle Linux, and RockeyLinux.
To change FTP port to some other port, edit file
1 |
vi /etc/pure-ftpd/pure-ftpd.conf |
Find
1 |
# Bind 127.0.0.1,21 |
Add below
1 |
Bind FTP_PORT_HERE |
Example
1 2 3 4 |
[root@backendz ~]# cat /etc/pure-ftpd/pure-ftpd.conf | grep -i bind # Bind 127.0.0.1,21 Bind 2121 [root@backendz ~]# |
This will change FTP port to 2121.
Restart pure-ftpd with command.
1 |
systemctl start pure-ftpd |