Quick FTP server setup with VSFTPD on Ubuntu

Well my dream of writing a lengthy blog post to really christen this new blog went slightly awry this weekend – we can put that down to a mixture of snow-related excitement and Godfatherly-related travels. Either way, I’ve only had time to put together this quick post regarding how to set up an FTP server on Linux using VSFTPD.

I should quickly note that setting up an FTP server is not something I do very often, there are probably better ways to do it, and there are probably better people out there to advise you how to do it. The fact that you’re still reading this though probably implies you’re not going to go to those other sources to get your FTP-related goodness, so here it is…

Setting up an FTP server couldn’t really be easier with VSFTPD and Ubuntu (I’m using Ubuntu 11.04 – Natty Narwhal), as you’ll hopefully agree!

Update your packages list
Always a useful step – make sure you’re working from the latest package list.

Install VSFTPD
Well, it’s not going to work without it is it?

Configure VSFTPD
You weren’t going to get off that lightly, there is actually a little bit of work to be done! First, open up the VSFTPD config file with your chosen editor (mine’s nano).

First, make sure anonymous access is turned off by making sure the line reading the following is neither commented out nor has “YES” as the setting (if so, it should read as follows):

Rather appropriately, the next part allows local users to log in:

And finally, if you wish to let users modify files change the line for allowing write access to read:

Set up your users

In the simplest form of this setup the user’s home directory is what you see when you log in via FTP, therefore you can either create a new user and have their home directory (default is /home/username) as follows:

or specify a directory that you’ve created to act as the user’s home directory with:

once you’ve added you need to create and confirm a password for the user with:

Only one thing left to do…

Now you can restart the vsftpd service with the following command and test your new FTP server!

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS

4 thoughts on “Quick FTP server setup with VSFTPD on Ubuntu

    • Haha, good spot, yes, need to be either root or sudo all your commands.

      Post regarding configuration for SFTP coming soon…

  1. Pingback: Configure VSFTPD for SFTP connections using OpenSSL on Ubuntu

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">