Looking for ProFTPD create user option?
ProFTPD is an opensource software for uploading files to a server. It supports TLS (SSL) for securing connections.
By creating a user in Proftpd, it’s an easy task to upload or download files to the required folder.
At Bobcares, we often get requests from our customers for creating the ProFTPD user as part of our Server Management Services.
Today, let’s get into the details on how our Support Engineers help the customers to create the ProFTPD user.
Need for ProFTPD user?
Creating a user in ProFTPD is a simple task. This can simplify the task of uploading and downloading files by remote users like the developers of the website etc.
By default, the configuration file of ProFTPD is :
/etc/proftpd.conf
The installation of Proftp service is rather simple when using package managers like yum, apt-get, etc. However, for the user to upload or download files via FTP, there has to be a specific user associated with each folder. This requires adding FTP users.
How to add the user in ProFTPD
At Bobcares, where we have more than a decade of expertise in managing servers, we see many customers requesting to create users in ProFTPD.
Now, let’s see how our Support Engineers help the customer in creating ProFTPD users.
Creating ProFTPD Users
The Proftpd user creation involves a series of steps.
We begin by creating the FTP user by the following command,
useradd username
After that, we create a password for this user.
passwd username
Usually, the home directory for the “proftpd” user will be set to the default home directory, which may not be useful.
So we need to modify the home directory of the FTP user. To set a new user with the /var/www/ folder as the home folder for accessing easily, we use:
usermod -m -d /var/www/ username
Finally, we restart the Proftd service.
service proftpd restart
Now it is very easy to access from the FTP server. We also suggest the customers to use Filezilla or any other FTP client to access the FTP server.
Configuring virtual users
Usually, ProFTPD uses the system’s /etc/passwd file by default so its users are the same as system users. Virtual users are defined as FTP-only user accounts.
These users login to proftpd, but who are separated from the normal system users, and who do not have entries in /etc/passwd. Here the user data was fetched via a name, a UID, a GID, a home directory, and a shell.
We helped the customers in configuring ProFTPd with virtual users by following steps.
Initially, we opened the ProFTPd configuration file.
/etc/proftpd/proftpd.conf
Specify the following parameters in the configuration file.
Here, mod_auth_file.c is used for authorization of users. Hence, the logins and passwords are taken from /etc/proftpd/ftpd.passwd file.
After this, we have create the test user.
ftpasswd --passwd --file=/etc/proftpd/ftpd.passwd --name=test --uid=60 --gid=60 --home=/srv/ftp/test/ --shell=/bin/false
As a result of this command, a new file /etc/proftpd/ftpd.passwd file will be created, which is similar to /etc/passwd.
We can specify any UID or GID except 0 since its for root.
In this command, we can use any UID or GID and also even UID or GID of the user in /etc/passwd.
Then we check the configuration is proper or not by the following command.
proftpd -t
Finally, we restarted the ProFTPd for applying the changes made.
/etc/init.d/proftpd restart
The user password in the file is created in an encrypted format, so we change the password by the following command.
ftpasswd --passwd --file=/etc/proftpd/ftpd.passwd --name=test --change-password
We provide the FTP username and password to the customer to connect via FTP.
[Having trouble creating ProFTPd users? We are available 24×7 to help you.]
Conclusion
In short, ProFTPD creates users either via default method or via virtual users. Today, we discussed it in detail and saw how our Support Engineers properly added FTP users for our customers.
Hi, is “passwd” in the example “ftpasswd –passwd –” the actual password? Eg: ftpasswd –Mypa55wd! –“
Also what is the purpose of adding AuthGroupFile /etc/proftpd/ftpd.group to the conf file?
Should we create ftpd.group and what should we put in it?
Thanks.
Hello Mark,
Also, the AuthGroupFile helps to set restrictions on files for certain groups. For this, we need to use the ftpasswd command with –group option. This can create the ftpd.group file or update existing ones.
Hello Mark,
The ftpasswd command will prompt for the password. That’s where you need to set your desired password.
Actually the default file is: /etc/proftpd/proftpd.conf
Hello Roy,
Default file in RHEL/CentOS server is /etc/proftpd.conf and default file in Ubuntu/Debian server is /etc/proftpd/proftpd.conf.