1834164 Members
2466 Online
110064 Solutions
New Discussion

Creating a FTP log

 
SOLVED
Go to solution
TheJuiceman
Super Advisor

Creating a FTP log

Hey gang,

Is there a way to have all of the FTP information that populates the syslog go to a separate "ftp" log? As always, your help is very appreciated!!!
2 REPLIES 2
Bill Hassell
Honored Contributor
Solution

Re: Creating a FTP log

Yes. It isn't documented very well but ftpd sends it's information using the local5 facility name. So you change /etc/syslog.conf from this:

*.info;mail.none /var/adm/syslog/syslog.log

to:

*.info;mail.none;local5.none /var/adm/syslog/syslog.log
local5.info /var/adm/syslog/ftp.log

Then tell syslogd to reread the config file:

kill -HUP $(cat /var/run/syslog.pid)

Now, a new logfile called ftp.log will have all the ftp details. This concept can be extended to other logs:

*.info;mail.none;local5.none;auth.none /var/adm/syslog/syslog.log
auth.info /var/adm/syslog/auth.log
local5.info /var/adm/syslog/ftp.log

which will log authentication details into auth.log and ftpd into ftp.log. Now syslog will be much easier to read.


Bill Hassell, sysadmin
TheJuiceman
Super Advisor

Re: Creating a FTP log

Perfect!!! Thank you so much!!!