How to trigger Event Handler only when there is a HARD state

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
caterpillartce
Posts: 117
Joined: Mon Jul 11, 2016 11:22 am

How to trigger Event Handler only when there is a HARD state

Post by caterpillartce »

Hello,

I am using Event Handler to send alerts as tickets to BMC Remedy. However it seems like we are getting tickets even when there is only SOFT state change, so we are getting more tickets than real alerts. Is there a way to only trigger Event Handler when there is a HARD state change?

Thanks!
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: How to trigger Event Handler only when there is a HARD s

Post by avandemore »

No, you would need to build logic into your event handler to be smart enough to act appropriately with the information.

This is the type of data you would need to pass into your event handler:

https://assets.nagios.com/downloads/nag ... olist.html

We do offer custom development for a fee. Let me know if you are interested and I'll get you in touch with the right people.
Previous Nagios employee
SteveBeauchemin
Posts: 524
Joined: Mon Oct 14, 2013 7:19 pm

Re: How to trigger Event Handler only when there is a HARD s

Post by SteveBeauchemin »

From the link you have been provided, and drilling in one level, you can see an example SH file shown that does exactly what you want.

It checks the soft states, and you can tell it that when it gets HARD to do something. That was a perfect link to provide by @avandemore.

The script is in here... https://assets.nagios.com/downloads/nag ... dlers.html
Just re-purpose it to what you need.

Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: How to trigger Event Handler only when there is a HARD s

Post by dwhitfield »

For clarity, Adam's "no" was that there's not a check box for this. Steve provided a more specific link (thanks!), but Adam's link is important for going forward. You may need different logic in the future, and those macros are the key.
Locked