How to Change Your FTP Port

Rate this post

Lately FTP has been a problem for a lot of hosting providers. Especially since the recent influx of Gumblar-related attacks and FTP exploits, some hosting providers are now considering changing their FTP ports as an added measure of security. If you're on a cPanel server you have a couple extra steps to go through, but it's a rather easy change.

Pure-FTP

1) Edit /etc/pure-ftpd.conf and look for the following line:

Bind

Where is a publically routable IP.  The default example, 127.0.0.1, will cause the socket to bind locally but then this connection won't serve externally. is the new port you wish to put the service on.

2) If necessary, add the new FTP port to your server's firewall

3) Edit /etc/chkserv.d/ftpd and change the port, which is the first comma-separated entry to the right of '=' on the line in the file, to match the port you put the service on.

Finally:

/etc/init.d/pure-ftpd restart
/etc/init.d/cpanel restart (restarts tailwatchd/chkservd)

ProFTP

Edit /etc/proftpd.conf and change:

Port 21

Then make sure to test to make sure FTP is working before notifying your users!

zp8497586rq
Don't be selfish, share!Tweet about this on TwitterShare on RedditShare on TumblrBuffer this pageDigg thisShare on FacebookFlattr the authorEmail this to someoneShare on Google+Pin on PinterestPrint this pageShare on LinkedInShare on StumbleUpon

6 Comments

  1. Pingback: Securing FTP Access on a cPanel Server :: The cPanel Admin

  2. Esponjito

    Great tip, thank you, i just modify one server for testing. I would add a little tip too, to the tutorial. that people that change their port, is they have a firewall enabled, make sure open the port on iptables!

  3. Pingback: Cant change ftp port, chkserv.d/ftpd file always back using original file | GeekFreak

  4. Pingback: Cant change ftp port, chkserv.d/ftpd file always back using original file | DC2NET Links

  5. Pingback: Cant change ftp port, chkserv.d/ftpd file always back using original file | HostGator Coupons Code

  6. Pingback: Securing FTP Access on a cPanel Server

Log in