(ve):Install ProFTPD on Ubuntu

  • This page was last modified on February 7, 2011, at 12:16.
The (mt) Community Wiki is a collaborative project. Any (mt) Media Temple customer or employee may contribute. Not all articles and/or content have been tested for accuracy by (mt) Media Temple.

For officially moderated and tested articles, be sure to visit our KnowledgeBase.

From (mt) Community Wiki

Contents


ProFTPD is an FTP server. The ProFTPD server is a configurable GPL-licensed FTP server software for Linux and Unix based operating systems. Best part? It only uses one config file!

Before you start

You will need to have Ubuntu installed on your (ve) Server. Please read this article for more information: (ve):Change Operating System.

Install

To make installations a breeze, you can install debconf-utils on a working Linux system, then run debconf-get-selections. Here's the code:

echo "proftpd-basic shared/proftpd/inetd_or_standalone select standalone" | debconf-set-selections

Next, install ProFTPD:

aptitude -y install proftpd-basic

Be sure to make a backup of the configuration file.

cp /etc/proftpd/proftpd.conf /etc/proftpd/proftpd.conf.bak

Now, we'll remove IPv6 support:

sed -i 's/.*UseIPv6.*/UseIPv6 off/g' /etc/proftpd/proftpd.conf

Remember, replace example.com with your hostname:

perl -p -i -e 's|Debian|example.com|g;' /etc/proftpd/proftpd.conf


The RequireValidShell directive configures the server, virtual host or anonymous login to allow or deny logins which do not have a shell binary listed in /etc/shells. By default, proftpd disallows logins if the user's default shell is not listed in /etc/shells. If /etc/shells cannot be found, all default shells are assumed to be valid. I prefer to remove ssh access for ftp users. This is optional.

sed -i 's/.*RequireValidShell.*/RequireValidShell off/g'/etc/proftpd/proftpd.conf

Let's restart ProFTPD:

service proftpd restart

Assign a password for the user www-data:

echo "www-data:lolsecurepassword" | chpasswd

Now, fire up your favourite FTP client and connect.

Notes/Supplemental