I want to keep 30-60 days of the “full” files for logs. I’m pretty sure I need to edit this file listed below. I’m assuming I would need to add a segment for the section that says “/var/log/asterisk/full.” Any expert advise would be great.
/etc/logrotate.d/asterisk
File Contents:
/var/log/asterisk/queue_log {
daily
missingok
rotate 30
notifempty
sharedscripts
create 0640 asterisk asterisk
}
/var/log/asterisk/freepbx_dbug{
size 500M
missingok
rotate 7
notifempty
sharedscripts
create 0640 asterisk asterisk
}
/var/log/asterisk/prosody_debug.log
/var/log/asterisk/prosody.log
/var/log/asterisk/ucp_err.log
/var/log/asterisk/ucp_forever.log
/var/log/asterisk/ucp_out.log
/var/log/asterisk/freepbx_debug
/var/log/asterisk/freepbx.log
/var/log/asterisk/freepbx_security.log {
size 100M
missingok
rotate 7
notifempty
sharedscripts
create 0640 asterisk asterisk
}
/var/spool/mail/asterisk
/var/log/asterisk/messages
/var/log/asterisk/event_log
/var/log/asterisk/full
/var/log/asterisk/dtmf
/var/log/asterisk/fail2ban {
daily
missingok
rotate 7
notifempty
sharedscripts
create 0640 asterisk asterisk
postrotate
/usr/sbin/asterisk -rx ‘logger reload’ > /dev/null 2> /dev/null
endscript
}