Spiga

Change default FTP port in Fedora Core 6

(Question)

I have built an FTP server on my Fedora Core 6 box using vsftpd. Now what I want is to change the default port from 21 for security reasons. I have no problem in instructing my users to use a different port instead of the default port. But the problem is that I don't know how to change this on my server, Can you please help?

(Answer)

vsftpd is an FTP server that can run on most of the Linux distributions. It is really a good idea to change the default port. To do this, all you need is to edit the configuration file located at

/etc/vsftp/vsftpd.conf or /etc/vsftpd.conf
Log in as the root user and open vsftpd.conf file in any text editor and search for the following line:
listen_port =21
Now replace port 21 with any new port such as 205.
listen_port =205
Save and exit the file. Please make sure no other service is using 205 port.
Restart vsftpd as follows:
# /etc/init.d/vsftpd restart
Now to access the FTP server, just add the new port number as follows:
ftp ftp.myftpserver.com 205
From Linux For You Magazine (Q and A Section)
Organize by Vipin Sharma from New Horizons India Ltd-
Senior Corporate Manager - Technical



Related Posts by Categories



Widget by Hoctro | Jack Book

0 comments: