How to setup FTP Server Ubuntu 14.04

ftp server ubuntu

How to Setup FTP Server Ubuntu 14.04

I was following a tutorial to set this up on an AWS server and kept getting the same error: “Server sent passive reply with unroutable address. Using server address instead. Failed to retrieve directory listing.” I learned that FTP uses not only port 21, but another which is configured in your vsftpd.conf file. Here’s how to setup FTP Server Ubuntu 14.04.

Install VSFTPD

sudo apt-get update
sudo apt-get install vsftpd

Edit Config File

open /etc/vsftpd.conf and uncomment these lines (29, 33, 120):
write_enable=YES
local_umask=022
chroot_local_user=YES
Add the following to the end of the file:
allow_writeable_chroot=YES
pasv_enable=Yes
pasv_max_port=12100
pasv_min_port=12000
Save and exit. Restart VSFTPD.
sudo service vsftpd restart

Add ftp user to Ubuntu

sudo useradd -m jordan -s /usr/sbin/nologin
sudo passwd jordan

Allow login access for nologin shell

Add this line to the end of /etc/shells:
/usr/sbin/nologin

Make sure you have all of the ports open in your firewall (21,12000-12100)

Enjoy!

READ  First HTML Page

Leave a Reply

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