Hi, Since yesterday my Asterisk 1.2.3 is displaying the following message every few seconds>Asterisk Event Logger restarted >Rotated Logs Per SIGXFSZ (Exceeded file size limit)This causes my log files (verbose, queue_log) to become huge with lots of logger rotate messages, but I don't know which files is exceeding size limit, since even if I delete all log files I still get this message. Any way, I have plenty of disk space and couldn't find the reason for this message. Please help me identify the issue! Dov -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060209/4c69633c/attachment.htm
I found the problem. Master.csv reached 2.0GB and since the moment this happened Asterisk went crazy! Since I am using cdr-mysql, how do I disable the use of csvs? Thank you Dov ----- Original Message ----- From: Dov Bigio To: asterisk-users@lists.digium.com Sent: Thursday, February 09, 2006 10:56 AM Subject: asterisk logger - urgent!!! Hi, Since yesterday my Asterisk 1.2.3 is displaying the following message every few seconds >Asterisk Event Logger restarted >Rotated Logs Per SIGXFSZ (Exceeded file size limit) This causes my log files (verbose, queue_log) to become huge with lots of logger rotate messages, but I don't know which files is exceeding size limit, since even if I delete all log files I still get this message. Any way, I have plenty of disk space and couldn't find the reason for this message. Please help me identify the issue! Dov -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060209/18f750c7/attachment.htm
On Thu, Feb 09, 2006 at 10:56:18AM -0200, Dov Bigio wrote:> Hi, > > Since yesterday my Asterisk 1.2.3 is displaying the following message every few seconds > > >Asterisk Event Logger restarted > >Rotated Logs Per SIGXFSZ (Exceeded file size limit) > > This causes my log files (verbose, queue_log) to become huge with lots > of logger rotate messages, but I don't know which files is exceeding > size limit, since even if I delete all log files I still get this message.Unrelated to the origin of the problem: Do you run 'logger reload' after deleting those logs? Otherwise Asterisk still writes to the old (deleted) logs> > Any way, I have plenty of disk space and couldn't find the reason for this message. > > Please help me identify the issue! > Dov >> _______________________________________________ > --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-- Tzafrir Cohen | tzafrir@jbr.cohens.org.il | VIM is http://tzafrir.org.il | | a Mutt's tzafrir@cohens.org.il | | best ICQ# 16849755 | | friend
Perhaps there's a happy medium: sprintf()? I am curious to know if putting the output into a char array with sprintf() (to preserve the output formatting) and then writing it with write(). How much additional overhead would this take? Hard to know without trying it. Is anyone in a position to write some test code that would do this and report back the results? -MC -----Original Message----- From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of Kevin P. Fleming Sent: Saturday, February 11, 2006 7:39 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [Asterisk-Users] asterisk logger - urgent!!! Bob Goddard wrote:> Using fopen/fputs to ONLY append to a file, is quite frankly, stupid. > Change it to open/write and you will be able to trap via the write > return code and errno.Patches to fix bugs are most welcome. Given that these files are written using fprintf (because they are using format strings and long lists of arguments), using write will require allocating memory, building the output there and then calling write(). Seems like an awful lot of work to avoid a simple system administration failure. _______________________________________________ --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
Kevin, I agree with your assessment of the preference of using fprintf() instead of sprintf() + write() + maybe malloc(). After hearing your candid explanation it makes perfect sense not to pursue this. I've only been playing with * for two months, so I'm still gathering my bearings. As for my C skills- I must admit that it's been many years since I did any real work with C or C++. (I've been side-tracked with Visual Studio projects and using Perl to get data flowing in a very OS-heterogonous environment.) On top of that, I've been busy learning to use * and I'm just now starting to dive into the considerable amount of * source code. However, I wouldn't be so quick to stifle ideas - even "bad" ones. Everyone who read this thread now knows that making * do the administrative work is not only impractical, but now they have ample information as to _why_ it is impractical. All ideas have some value, even if they represent how not to do something. Besides, occasionally an idea starts out small and turns big. After all, didn't some guy named Mark have an idea to get dial tone out of a computer to save some money on a phone system? Who knew that the idea of dial-tone-in-a-box would spark a telephony revolution? :-) -MC -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060211/45ac8001/attachment.htm
You may not be able to disable the logs but if you do not care about the information you cal always link to /dev/null Ie ln -s /path/to/log/file /dev/null> -----Original Message----- > From: asterisk-users-bounces@lists.digium.com > [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of > Simone Cittadini > Sent: Monday, February 13, 2006 5:51 AM > To: Dov Bigio; Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [Asterisk-Users] Re: asterisk logger - urgent!!! > > Dov Bigio ha scritto: > > > I found the problem. > > > > Master.csv reached 2.0GB and since the moment this happened > Asterisk > > went crazy! > > > > Since I am using cdr-mysql, how do I disable the use of csvs? > > > > Thank you > > Dov > > Why don't you simply rotate the logs with logrotate ? > (no, I don't know how to disable them) > _______________________________________________ > --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 >