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: [EMAIL PROTECTED]' 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 [email protected] 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
