Managing FTP accounts on a CentOS system involves inspecting the configuration files and user lists associated with your FTP server software. Common FTP servers on CentOS include vsftpd, proftpd, and pure-ftpd. Below are the steps to check user accounts for each of these servers.
1. vsftpd
vsftpd (Very Secure FTP Daemon) is a widely used FTP server for Unix-like systems.
Checking User Accounts
- Local Users: If your FTP server is configured to allow local system users to log in, list these users by inspecting the
/etc/passwdfile:cat /etc/passwd - Virtual Users: If virtual users are configured, they might be defined in a separate file. Look for the
user_config_dirin thevsftpdconfiguration to find this file:grep -i "user_config_dir" /etc/vsftpd/vsftpd.conf - Anonymous Users: If anonymous FTP is enabled, you can verify this in the configuration file
/etc/vsftpd/vsftpd.confby finding the following line:anonymous_enable=YES
Configuration Files
- Main configuration file:
/etc/vsftpd/vsftpd.conf
2. proftpd
proftpd is another popular FTP server.
Checking User Accounts
- Local Users: Similar to
vsftpd, check the local users in the/etc/passwdfile:cat /etc/passwd - Virtual Users: Virtual users might be stored in a separate file or database. Look for
AuthUserFileor similar directives in theproftpdconfiguration:grep -i "AuthUserFile" /etc/proftpd/proftpd.conf
Configuration Files
- Main configuration file:
/etc/proftpd/proftpd.conf
3. pure-ftpd
pure-ftpd is a lightweight FTP server.
Checking User Accounts
- Local Users: As with the other servers, check
/etc/passwdfor local users:cat /etc/passwd - Virtual Users: Virtual users for
pure-ftpdmight be managed using a separate file or database. Check thepure-ftpdconfiguration for details.
Configuration Files
- Main configuration file:
/etc/pure-ftpd/pure-ftpd.conf
Additional Tips
- Service Management: To check if the FTP service is running, you can use:
systemctl status vsftpd systemctl status proftpd systemctl status pure-ftpd - User-Specific Configurations: FTP servers may have user-specific settings in separate directories, such as
/etc/vsftpd/user_conf/forvsftpd. - Logs: Reviewing log files can also provide information about FTP accounts and activity:
/var/log/vsftpd.log /var/log/proftpd/proftpd.log /var/log/pure-ftpd/pure-ftpd.log
By examining these files and configurations, you can gather all necessary information about the FTP accounts configured on your CentOS system.

沒有評論