How to install FTP
The
daemon is included in most versions of Linux. If you are using a Debian based
distribution like Mint or Ubuntu, open a terminal window and type: sudo apt-get
install vsftpd
If you are using a Red Hat based disto, open a terminal window
and type: sudo yum install vsftp
How to
configure FTP
To
configure vsftp, open the vsftpd.conf file in the /etc directory. For instance,
if you were using gedit as your text editor, you would type: sudo gedit /etc/vsftpd.conf
First, for a secure setup, you’ll want to disable anonymous access
to your ftp server. Change this line: anonymous_enable=YES to anonymous_enable=NO
With anonymous access disabled, you’ll want to allow local users
to log in, by uncommenting the following line: #local_enable=YES to local_enable=YES (simply remove the # sign).
Allow write access by uncommenting this line: #write_enable=YES to write_enable=YES
Save and close the file.
Setup an FTP user account:
sudo mkdir -p /home/ftp/ftpuser
sudo useradd ftpuser -d /home/ftp/ftpuser -s /bin/false
sudo passwd ftpuser
sudo useradd ftpuser -d /home/ftp/ftpuser -s /bin/false
sudo passwd ftpuser
Restart your ftp server:
Debian: sudo etc/init.d/vsftpd restart
Red Hat: sudo service vsftpd restart
Test:
netstat -a | grep ftp
No comments:
Post a Comment