In this blog post, I am going to discuss that how ftp server is install and configured on local machine. Firstly install the Ftp server on local machine. I am using Ubuntu 12.04.
To install ftp server on ubuntu machine:
1 |
sudo apt-get install vsftpd |
Ftp server can be access in two mode
Anonymous mode
In this, remote clients can access the FTP server by using the default user account called “anonymous”. Anonymous FTP is called anonymous because you don’t need to identify yourself before accessing files. In general, you enter the word anonymous or ftp when the host prompts you for a username; you can enter anything for the password, such as your e-mail address or simply the word “guest”. For anonymous download from FTP server, server is configured to allow anonymous user.
1 |
sudo gedit /etc/vsftpd.conf |
uncomment the line :
1 |
anonymous_enable=yes |
Authenticated mode
It is by default ON. In the Authenticated mode a user must have an account and a password.
Restart after changes
Changes are not reflected back to server configuration so server has to restart for make changes working.
1 |
sudo restart vsftpd |
Changing FTP server home directory
When user is logged in to FTP server as anonymous mode, the default directory accessible to client is /src/ftp . It can be change by command
cd home/username/
mkdir ftp
sudo usermod -d home/username/ftp ftp
Don’t forget restart the ftp server.
Upload files to FTP server
By default writing to vsftpd is disabled. So if try to upload file to server, it send an error message
550 Permission denied.To enable the uploading, set the writing permission
1 |
sudo gedit /etc/vsftpd.conf |
uncomment the line :
1 |
write_enable=YES |
To enable uploading for anonymous user, uncomment the line :
1 |
anon_upload_enable=YES |
Don’t forget restart the ftp server.
I hope it helped you. Thank you.
Recent Comments