This is a tutorial will show you how to set up your own FTP server in Ubuntu Linux. FTP has a multitude of uses. You can set up your own file storage website, just your own file storage computer, or do other things.
- Install a program called vsftpd. In order to do this, open up a command line and type sudo apt-get install vsftpd. You will be required to type in the root password and after that, just follow the instructions vsftpd gives you in order to install it.
- Change the configuration file. Get to the file browser and type /etc. Next scroll down and double click on a file called vsftpd.conf. Remember that lines that start with a ‘#’ are commented out:
- Disable anonymous access: Change the “anyonymous_enable” setting to NO and the “local_enable” setting to YES.
- Check the value of the “secure_chroot_dir” setting. This is the FTP Root Directory, where the files go that can be accessed via FTP.
- Restart the FTP server to enable your changes: in a shell window, type: sudo /etc/init.d/vsftpd restart
- Place the files you want to serve in the FTP Root Directory.
- It’s a good idea to go through the whole of the configuration file, and read the documentation as far as it makes sense to you. FTP can be used for many different things, and this default configuration might not be exactly what you were looking for. Also, have a look on the Ubuntu support wiki.
- If you want to access your FTP site via the internet, you can set up with a dynamic DNS site, so you don’t have to remember your IP. You will need to update the IP of your home internet manually, or set a program (like inadyn) to do it for you. You might eventually end up with tons of instances of inadyn running. Just kill them.
- Set up your router to have port forwarding on the ports used by ftp (20 and 21 TCP). It must forward to the IP address of the ftp server. This applies to other services (such as email)