Install the vsFTPd.
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install vsftpd
Step 2 :
Edit the configure file of vsFTPd.
sudo nano /etc/vsftpd.conf
Change the setting as the following.
# If you allow anonymous login then
anonymous_enable=YES
# If you do not allow anonymous login then
#anonymous_enable=NO
local_enable=YES
write_enable=YES
# Users are allowed to walk around at his directory only
chroot_local_user=YES
If you are behind a firewall or router, the following setting should be implemented and append to the end of the file.
pasv_enable=YES
#pasv_promiscuous=YES
pasv_min_port=50000
pasv_max_port=50100
# If your server's IP address is 192.168.0.15
pasv_address=192.168.0.15
#local_root=/home
Make sure port 20, 21, and 50000-50100 are opened at your firewall or router. The ports should be forwarded to and opened at the vsFTPd server. Anonymous user can be download the files at /home/ftp directory.
Since the current version of vsFTPd changed the chroot setting, you need to create a working directory at /home/samiux (for example), such as /home/samiux/my_ftpdir.
Step 3 :
sudo chmod 500 /home/samiux
sudo chmod 775 /home/samiux/my_ftpdir
Step 4 :
Restart vsFTPd.
sudo /etc/init.d/vsftpd restart
That's all. See you.
No comments:
Post a Comment