service performance logs

Olaf Hoyer ohoyer at gaff.hhhr.ision.net
Mon Jul 28 16:47:43 CEST 2003


On Mon, 28 Jul 2003, Williams, P. Lane wrote:

> I was wondering if anyone has a standard way of rotating your service
> performance logs.  I've been letting mine go for some time now and it has
> hit the 2G limit and of course that killed the Nagios process.  So I
> manually rotated the thing and all is well.
>
> I've tried using logrotate in the past, but after the rotation Nagios stops
> logging to it.  I assume because the application has a lock on the file and
> when rotated that changes.
>
Well, haven't run into this.
(OK, mostly running netsaint in the past)

nagios itself should have the ability to rotate the important logs...

Otherwise, as seen also with apps like apache, when you kick away the
log, you have to send a SIGHUP to the application, so that they start to
write the log again, because utils that rotate logs, will mostly place
the new, fresh log when touched, on a new inode, so the app will need a
SIGHUP to recognize this.
(Well, I mostly ran netsaint with FreeBSD, the newsyslog util there
(logrotate-like, in the base system) also has the possibility to tell
newsyslog which where the file with the pid can be found to be hup'ed.

Be careful, I've seen on hosts with large sums of services to check,
that a HUP does no good to netsaint, because before completing saving
retention data, it is up again...
Will mess certain things up.

HTH
Olaf

-- 
Olaf Hoyer        ohoyer at gaff.hhhr.ision.net
Fuerchterliche Erlebniss geben zu raten,
ob der, welcher sie erlebt, nicht etwas Fuerchterliches ist.
(Nietzsche, Jenseits von Gut und Boese)



-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list