Introduction
Pure FTPd (also known as Pure FTP) is a free, secure, and reliable FTP server that focuses on efficiency and ease of use.
In this tutorial, we’ll go step by step to show beginners how to install Pure-FTPd, perform the initial setup, and configure it properly on CentOS 7.
What is Pure FTPd?
Pure FTPd is a lightweight FTP server that supports modern features without unnecessary complexity. It is widely used for personal projects and hosting environments because it is:
- Free & secure (BSD license)
- Beginner-friendly
- Easy to configure with simple options
- Supports virtual users and chroot for security
If you are looking for a stable and simple FTP solution, Pure-FTPd is a great choice.
How to Set Up Pure FTPd on CentOS?
Step 1: Download Pure FTPd
First, we need to download the latest version of Pure FTPd.
wget https://download.pureftpd.org/pub/pure-ftpd/releases/pure-ftpd-1.0.47.tar.bz2
tar -xvjf pure-ftpd-1.0.47.tar.bz2
cd pure-ftpd-1.0.47Step 2: Install Pure FTPd with All Options
Now, configure and compile the installation.
./configure --prefix=/usr/local/pure-ftpd/ --with-everything
make
make installThis installs Pure-FTPd in /usr/local/pure-ftpd/.
Step 3: Pure FTPd Configuration File
Change into the configuration directory:
cd /usr/local/pure-ftpd/etc/
vi pure-ftpd.confUpdate these settings:
ChrootEveryone yes
NoAnonymous yes
UnixAuthentication no
PureDB /usr/local/pure-ftpd/etc/pureftpd.pdbMake sure the PureDB path matches your installation.
Step 4: Update Environment Path
Add Pure-FTPd binary to your PATH:
export PATH=$PATH:/usr/local/pure-ftpd/binStep 5: Create FTP User and Group
groupadd ftpgroup
useradd ftpuser -g ftpgroup -d /dev/null -s /sbin/nologinThis ensures FTP users are separated from system users.
Step 6: Create a Virtual User
- Create a directory for your site:
mkdir -p /var/www/site1
chown ftpuser:ftpgroup /var/www/site1 -R- Add a virtual FTP user:
pure-pw useradd user1 -u ftpuser -g ftpgroup -d /var/www/site1 -m- Build the PureDB database:
pure-pw mkdb- Check the user details:
pure-pw show user1Step 7: Open Firewall Ports
To allow FTP traffic:
firewall-cmd --add-port=21/tcp
firewall-cmd --add-port=30000-50000/tcp
firewall-cmd --list-portsStep 8: Pure FTPd Setup Finished
Finally, start the FTP server:
/usr/local/pure-ftpd/sbin/pure-ftpd -j -lpuredb:/usr/local/pure-ftpd/etc/pureftpd.pdb &Step 9: Done! Test Your FTP Server
Your Pure FTP server is now running. You can connect using your favorite FTP client (like FileZilla) with the virtual user you created.
Conclusion
Setting up Pure FTPd on CentOS 7 is straightforward, even for beginners.
You have learned how to:
- Download Pure-FTPd
- Install and configure Pure FTP
- Create virtual users
- Set up firewall rules
- Start the Pure FTP server
With this Pure FTPd setup, you now have a secure and efficient FTP solution ready for use.
ftp user, ftp users
