[OPEN-ILS-GENERAL] Suggestion for logrotate

Mike Rylander mrylander at gmail.com
Thu Sep 4 16:39:19 EDT 2008


On Thu, Sep 4, 2008 at 4:37 PM, Bill Erickson <erickson at esilibrary.com> wrote:
> On Thu, 04 Sep 2008 14:24:02 -0400, Syd Weidman <s.weidman at uwinnipeg.ca>
> wrote:
>
>> Hello!
>>
>> I want to implement a logrotate script for Evergreen (osrfsys.log is more
>> than 2GB already), but I need to know what to put in the postrotate section.
>> For example, in the default logrotate script for apache2, there is this bit:
>>
>>
>>        sharedscripts
>>        postrotate
>>                if [ -f /var/run/apache2.pid ]; then
>>                        /etc/init.d/apache2 restart > /dev/null
>>                fi
>>        endscript
>>
>> What provision should be made for getting the opensrf processes to write
>> to the newly rotated logfile? Should I just run:
>>
>> su -c '/openils/bin/osrf_ctl.sh -c /openils/conf/opensrf_core.xml -a
>> restart_all > /dev/null' opensrf
>
>
> Hi Syd,
>
> The C and Perl services currently open/close the file handle with each
> write, so simply moving the log file will cause a new one to be created and
> written to.
>
> Also, note that Syslog is an option for Evergreen if you need any additional
> logging speed/features.

Arg! Me and my time travel!  Bill is correct (he wrote the current
logging code) and I apologize for the mis-information.

Nothing to see here, move along... :)

-- 
Mike Rylander
 | VP, Research and Design
 | Equinox Software, Inc. / The Evergreen Experts
 | phone: 1-877-OPEN-ILS (673-6457)
 | email: miker at esilibrary.com
 | web: http://www.esilibrary.com


More information about the Open-ils-general mailing list