[clamav-users] Setting up logrotation
J.R.
themadbeaker at gmail.com
Tue Sep 24 18:21:31 UTC 2019
Log rotation done by clamav is totally separate than your system's log
rotation that is done by a cronjob...
Unless you are doing some serious debugging, there isn't a lot that is
written to the clamd & freshclam log files...
My daily clamd.log is maybe 2 KB, and freshclam.log maybe around 20 KB...
I've never used the internal ClamAV log rotation feature, but if you
want to create a file in your /etc/logrotate.d directory you can do
something like this:
For clamd:
/var/log/clamav/clamd.log {
missingok
notifempty
daily
compress
create 644 clam clam
postrotate
killall -HUP clamd 2>/dev/null || :
endscript
}
For freshclam (note: I run via cron job, not daemon):
/var/log/clamav/freshclam.log {
missingok
notifempty
daily
compress
create 644 clam clam
}
More information about the clamav-users
mailing list