Setup vsFTPd on Debian/Ubuntu

Updated on October 4, 2014
Setup vsFTPd on Debian/Ubuntu header image


vsftpd stands for Very Secure FTP Daemon. It's a lightweight FTP server. This short tutorial explains how to install vsftpd on Debian or Ubuntu. The commands in this tutorial require root privileges.

Step 1: Installation

Run the following command to install vsftpd:

apt-get install vsftpd

Step 2: Configuration

Open up the configuration file using your text editor of choice. This example uses vim.

vim /etc/vsftpd.conf

vsftpd allows anonymous users to access the server by default. This feature could be considered a security vulnerability. We will disable anonymous login by changing the following line:


To allow local user login, uncomment the following line:


To enable uploading, uncomment the following line:


Save the file and close your text editor. Then, start vsftpd as a daemon:

service vsftpd start

At this point, you can log in your ftp server from your local computer.


If you want to prevent all local users from leaving their home directory, you need to uncomment this line from /etc/vsftpd.conf:


As of vsftpd 2.3.5, the chroot directory must not be writable. You can change the permissions of this folder with the following command:

chmod a-w /home/user

Remember to restart the vsftpd daemon after editing vsftpd.conf.

service vsftpd restart