Page 1 of 1

screenlog does not roll on restart

PostPosted: Tue Oct 06, 2009 4:03 pm
by ronsrussell
On a new install (using VICIbox) I have cron job configured to restart nightly. But the screenlog does not roll over. ADMIN_restart_roll_logs.pl script is in /etc/init.d/vicidial init script but does not seem to work.

PostPosted: Mon Oct 12, 2009 11:19 pm
by williamconley
edit the file. at the end of the file we have:

Code: Select all
print "rolling Asterisk screen log...\n";
`mv -f /screenlog.0 /screenlog.0.$now_date`;

print "rolling Asterisk root screen log...\n";
`mv -f /root/screenlog.0 /root/screenlog.0.$now_date`;

print "rolling Asterisk var log screen log...\n";
`mv -f /var/log/asterisk/screenlog.0 /var/log/asterisk/screenlog.0.$now_date`;


print "FINISHED... EXITING\n";

exit;

add this:
Code: Select all
print "rolling Asterisk astguiclient screen log...\n";
`mv -f /var/log/astguiclient/screenlog.0 /var/log/astguiclient/screenlog.0.$now_date`;
and be sure your script has permission to run as well. test it from the command line.

PostPosted: Tue Oct 13, 2009 3:24 am
by ronsrussell
That worked.
Actually I modified the last line in the script by replacing "asterisk" with "astguiclient". And I modified the "ADMIN_restart_roll_logs.pl" file in both the /usr/share & the /usr/src directories.
Thanks for the good advice.