Patrick wrote:
On Tue, 2006-05-23 at 09:08 +0000, Tony Mountifield wrote:
[snip]
/var/log/asterisk/messages /var/log/asterisk/event_log
/var/log/asterisk/queue_log
/var/log/asterisk/h323_log /var/log/asterisk/cdr-custom/Master.csv {
missingok
notifempty
create 0640 asterisk asterisk
sharedscripts
postrotate
/usr/sbin/asterisk -rx 'logger rotate' >/dev/null 2>/dev/null || true
endscript
}
If logrotate is doing the rotation of the files, then I think you only
need asterisk to do "logger reload", not "logger rotate".
Good one. Thanks for the tip.
Some more comments: AFAIK the CDR files are closed after writing. Thus,
if logrotate rotetes the CDR, there is no need to execute asterisk -rx
'logger reload'. This is only needed if logrotate rotates the files in
/var/log/asterisk/.
Further, there is a deadlock bug: http://bugs.digium.com/view.php?id=7195
regards
klaus
PS: my /etc/logrotate.d/asterisk file:
/var/log/asterisk/messages /var/log/asterisk/*log {
daily
missingok
rotate 14
compress
delaycompress
postrotate
/usr/sbin/asterisk -rx 'logger reload' > /dev/null 2> /dev/null
endscript
}
/var/log/asterisk/cdr-csv/*csv /var/log/asterisk/cdr-custom/*csv {
monthly
missingok
rotate 6
compress
delaycompress
}
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --
Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users