FW: [Nagios-users] Notification Macros to Determine How Long Last State Duration

Larry Low llow at telesphere.com
Tue Mar 18 18:46:30 CET 2008


Figured this might be suited for nagios-devel since my assumption it is a bug or my misunderstanding...

Here is what I'm trying to figure out how to do.  I'm pretty sure with the current Nagios variables available this is not possible (3.0).

I have a perl script that is executed for notifications.  On notifications that are triggered from state changes I would like to print out how long the service was in a previous state before this new state occurred.

Example:

A) State is OK for 10 minutes (10 checks of ok separated by 1 minute)
B) State changes to CRITICAL
C) Notification triggered

LASTSERVICESTATECHANGE will be current time
LASTSERVICEOK will be 1 minute ago
LASTSERVICESTATE will be OK
LASTSERVICESTATECRITICAL will be current time

I'm thinking the problem is that LASTSERVICESTATECHANGE should be 10 minutes since LASTSERVICESTATE is OK.  Bug or misinterpretation of macro?

Thoughts?  Suggestions?

----
Larry Low
4150 N Drinkwater Blvd., 5th Floor
Scottsdale, AZ  85251
Office: 480.385.7045
E-mail: llow at telesphere.com'

Telesphere Networks, Inc



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/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

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/




More information about the Developers mailing list