Installing VsFTPd on Ubuntu Server

A small tutorial on how to install vsftpd and setup a separate user.

Please follow these steps to install vsftpd service on your ubuntu machine.

# adding a new local user
useradd -g ubuntu ftpuser

# change the password of the new user
passwd ftpuser

# checking the user information
id ftpuser

# checking the user group
groups ftpuser

# changing the group of the user
usermod -g ubuntu ftpuser

# installing and configuring vsftpd

sudo apt-get install vsftpd
sudo vim /etc/vsftpd.conf

# anonymous_enable=NO
# local_enable=YES
# write_enable=YES
# chroot_local_user=NO§
# to display the hidden files using the ftp client:
# hide_file=none
# force_dot_files=YES
# local_umask=000

sudo service vsftpd restart

# pam_service_name=ftp

# Enabling passive ports:

# pasv_enable=YES
# pasv_min_port=64000
# pasv_max_port=64321
# port_enable=YES
# pasv_address=[your public ip]
# pasv_addr_resolve=YES

after this, make sure that the port range 64000 - 64321 is enabled in your amazon ec2 security groups or iptables

# configuring ftp user home directory:  
sudo mkdir /home/ftpuser  
chown ftpuser:ubuntu /home/ftpuser

  • Connect using filezilla
  • Use active ftp connection

Publish Date: 2014-09-10