Rich Adamson wrote:> Running fc3 with current cvs-head... > > Is there a nice way to rotate the /var/log/asterisk/messages file without > shutting down asterisk? > > I'm currently rotating the log files via cron, however my script requires > asterisk to be shut down, which also kills any outstanding cli sessions > (eg, asterisk -rvvvvv). Would like to rotate the files without killing > the cli session. Any reasonable way to accomplish this?In the Asterisk console type: logger rotate Surely this would have come up in a google search. (You can find google at http://www.google.com - it's a search engine) -- Cheers, Matt Riddell _______________________________________________ http://www.sineapps.com/news.php (Daily Asterisk News - html) http://www.sineapps.com/rssfeed.php (Daily Asterisk News - rss)
Rich Adamson wrote:>Running fc3 with current cvs-head... > >Is there a nice way to rotate the /var/log/asterisk/messages file without >shutting down asterisk? > >I'm currently rotating the log files via cron, however my script requires >asterisk to be shut down, which also kills any outstanding cli sessions >(eg, asterisk -rvvvvv). Would like to rotate the files without killing >the cli session. Any reasonable way to accomplish this? > >Rich > >man logrotate
Running fc3 with current cvs-head... Is there a nice way to rotate the /var/log/asterisk/messages file without shutting down asterisk? I'm currently rotating the log files via cron, however my script requires asterisk to be shut down, which also kills any outstanding cli sessions (eg, asterisk -rvvvvv). Would like to rotate the files without killing the cli session. Any reasonable way to accomplish this? Rich
On Sun, Sep 11, 2005 at 10:26:38AM -0600, Rich Adamson wrote:> > Running fc3 with current cvs-head... > > Is there a nice way to rotate the /var/log/asterisk/messages file without > shutting down asterisk? > > I'm currently rotating the log files via cron, however my script requires > asterisk to be shut down, which also kills any outstanding cli sessions > (eg, asterisk -rvvvvv). Would like to rotate the files without killing > the cli session. Any reasonable way to accomplish this?Here's what Debian installs at /etc/logrotate.d/asterisk: /var/log/asterisk/cdr-csv/Master.csv /var/log/asterisk/debug /var/log/asterisk/event_log /var/log/asterisk/messages { weekly missingok rotate 4 sharedscripts postrotate /usr/sbin/invoke-rc.d asterisk logger-reload endscript } Naturally the post-rotate script may differ on your system. logger-reload is a glorified 'asterisk -rx logger reload' . logrotate is a standard part of most linux distros. -- Tzafrir Cohen | tzafrir@jbr.cohens.org.il | VIM is http://tzafrir.org.il | | a Mutt's tzafrir@cohens.org.il | | best ICQ# 16849755 | | friend
Try this after your done rotating your log: asterisk -rx reload This is what I use.. ..o-------------------------------------------------------o.. Brian Fertig Network/Systems Engineer IT Administrator Planet Telecom, Inc. Tampa,FL Office -----Original Message----- From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of Paul Sent: Sunday, September 11, 2005 12:22 PM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [Asterisk-Users] rotate * log file? Rich Adamson wrote:>Running fc3 with current cvs-head... > >Is there a nice way to rotate the /var/log/asterisk/messages filewithout>shutting down asterisk? > >I'm currently rotating the log files via cron, however my scriptrequires>asterisk to be shut down, which also kills any outstanding cli sessions >(eg, asterisk -rvvvvv). Would like to rotate the files without killing >the cli session. Any reasonable way to accomplish this? > >Rich > >man logrotate _______________________________________________ --Bandwidth and Colocation sponsored by Easynews.com -- Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users This email was scanned by: Mcafee GroupShield ---------------- CONFIDENTIAL DISCLAMER ---------------- All information provided in this email is considered confidential and proprietary of Planet Telecom, Inc. and Telecenter Inc. Use of this information by anyone other than the recipient or sender will be considered in breach of agreement.