This document describes how to set up a File Transfer Protocol (FTP) server on an Elemental Linux Server (ELS) machine using ProFTPD.
You will need to have the ELS 'Extra Applications' CD-ROM mounted on /media/cdrom.
The following instructions describe how to install ProFTPD using the ELS CD-ROM.
The example below shows how you would install version 1.3.4a of ProFTPD from the ELS CD-ROM.
cd / tar -zxf /mount/cdrom/extra/proftpd-1.3.4a.i586.tar.gz cd /opt/bin ln -s ../proftpd-1.3.4a/bin/* . cd /opt/sbin ln -s ../proftpd-1.3.4a/sbin/* .
After installing ProFTPD, follow the steps below to configure ProFTPD as an FTP server with the option of anonymous logins.
The example below shows how to create the ProFTPD configuration directory and copy the proftpd.conf file. It also shows the changes to /etc/firewall as well as the commands used to set proftpd for automatic start-up.
mkdir /etc/opt/proftpd cp /opt/proftpd-1.3.4a/etc/proftpd.conf /etc/opt/proftpd/proftpd.conf vi /etc/firewall -A INPUT -p tcp -s 192.168.1.0/24 --dport 21 -j ACCEPT /etc/init.d/network restart chmod +x /etc/init.d/proftpd
The IP address range shown above is for demonstration purposes only and should be changed to match your network configuration.
You can test your setup by downloading some files via FTP.
Here is an example of a successful test.
login: root password: # /etc/init.d/proftpd start FTP server is starting. # ftp 127.0.0.1 Connected to 127.0.0.1. 220 ProFTPD 1.3.4a Server (ProFTPD Default Installation) [127.0.0.1] Name (127.0.0.1:root): joe 331 Password required for joe Password: 230 User joe logged in Remote system type is UNIX. Using binary mode to transfer files. ftp> cd /etc 250 CWD command successful ftp> get passwd local: passwd remote: passwd 227 Entering Passive Mode (127,0,0,1,145,254). 150 Opening BINARY mode data connection for passwd (214 bytes) 226 Transfer complete 214 bytes received in 0.000192 secs (1.1e+03 Kbytes/sec) ftp> quit 221 Goodbye. # cat passwd root::0:0:Super User:/root:/usr/bin/bash bin:x:1:1:Legacy UID:/bin:/bin/false daemon:x:2:2:Legacy UID:/sbin:/bin/false nobody:x:99:98:Nobody:/tmp:/bin/false joe:501:500:/home/joe/usr/bin/bash
If your test was not successful, here are some troubleshooting tips.
The ProFTPD website has a collection of documentation that may be helpful.