Quick Tip - Configure vsFTPd logging

Recently I had to do work with a client who was having issues with vsftpd on one of their servers. Sadly logging hadn’t been turned on. Since I always have an issue getting logs to populate with vsftpd I thought it would be a good idea to put it down in writing.

To turn on logging, create both of these files.

# touch /var/log/xferlog
#touch /var/log/vsftpd.log

Add the following settings to the vsftpd config file (/etc/vsftpd/vsftpd.conf)

dual_log_enable=NO
log_ftp_protocol=NO
vsftpd_log_file=/var/log/vsftpd.log
xferlog_enable=YES
xferlog_std_format=NO
xferlog_file=/var/log/xferlog

Save and exit the file. Restart the vsftpd service.

# service vsftpd restart

Login to your FTP server and you should see your vsftpd log file being populated.

Credit to to Calomel for the excellent VSFTPd tutorial