|Summary:||ASTERISK-20189: add a none rotatestrategy that disables internal log rotation|
|Reporter:||Jaco Kroon (jkroon)||Labels:|
|Date Opened:||2012-08-02 08:37:56||Date Closed:||2012-09-12 12:17:07|
|Environment:||Attachments:||( 0) asterisk-logger-norotate.patch|
( 1) asterisk-logger-norotate.patch
( 2) asterisk-logger-norotate-trunk.patch
|Description:||We are using an external log rotation mechanism and have a need to disable asterisk's internal rotation that kicks in at 1GB.|
The patch I'm about to attach achieves this for us by adding a none strategy on the rotation.
A further enhancement could be to implement a maxlogsize option, which will enable a user to set the size at which the automatic rotation happens, and when set to 0 disables the size based rotation, but still allow rotation via logger reload. We're not interested in this and want to disable rotation entirely.
|Comments:||By: Jaco Kroon (jkroon) 2012-08-02 08:45:59.050-0500|
Fixed a minor (but critical) bug from previous version. Previous version would have leaked the file descriptors of the log files on rotate.
Not sure if this can be improved by skipping the entire logchannels list traversal can be skipped.
By: Rusty Newton (rnewton) 2012-08-02 17:26:49.535-0500
Jaco, Thanks for the contribution! New features and improvements must be written against trunk. Can you provide a patch against trunk?
By: Jaco Kroon (jkroon) 2012-08-10 05:38:12.136-0500
rediffed against trunk.
original applied with some fuzz, also this patch will function with -p0 instead of -p1 as recommended by an external source.