LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (https://www.linuxquestions.org/questions/linux-security-4/)
-   -   how to logrotate auth.log files? (https://www.linuxquestions.org/questions/linux-security-4/how-to-logrotate-auth-log-files-391115/)

clintcan 12-09-2005 08:08 PM

how to logrotate auth.log files?
 
Hi guys,

I'm a bit new in creating logrotate files, but, is this the proper way to do it?

/var/log/auth.log {
missingok
daily
mail www@site.org
compress
rotate 4
}

Thanks.

peter_robb 12-10-2005 04:55 PM

Looks good.
You may find the mail command doesn't send it outside of your box tho'

You could use nail..
eg..
postrotate
/usr/bin/nail -s "Dansguardian access.log" -a /var/log/dansguardian/access.log.1.gz -A andrzej www@site.org < /root/dg.msg
endscript

It requires detailing the -A account used and a message file to provide text fot the email body.


All times are GMT -5. The time now is 09:29 AM.