How to pass flapping information macro to event handler?
Posted: Mon May 10, 2021 4:08 pm
I'm looking for same macro as $NOTIFICATIONTYPE$ which tell during notification that type of notification that is being sent ("PROBLEM", "RECOVERY", "ACKNOWLEDGEMENT", "FLAPPINGSTART", "FLAPPINGSTOP", "FLAPPINGDISABLED", "DOWNTIMESTART", "DOWNTIMEEND", or "DOWNTIMECANCELLED").
But problem with this macro is, we can use this macro with notification handler but not with event handler. When I use this macro in my event handler it give me blank.
Now, I'm looking for a macro that, I can send to my event handler, so that it can tell me whether host/service flapping has been started or not.
I tried using $HOSTPERCENTCHANGE$ but not happy/understand with the result. If no macro is available, how can I get this info whether flapping has been started.
What, I'm trying to achieve is stop processing SNMP traps being sent, if host/service start flapping. Nagios write the code don't send SNMP traps during downtime, but how can I stop sending SNMP traps while host/service is flapping.
Well I edited my code.Once I get flapping start, I'll put my if condition and stop it for further processing.
Please help me to sort this out.
But problem with this macro is, we can use this macro with notification handler but not with event handler. When I use this macro in my event handler it give me blank.
Now, I'm looking for a macro that, I can send to my event handler, so that it can tell me whether host/service flapping has been started or not.
I tried using $HOSTPERCENTCHANGE$ but not happy/understand with the result. If no macro is available, how can I get this info whether flapping has been started.
What, I'm trying to achieve is stop processing SNMP traps being sent, if host/service start flapping. Nagios write the code don't send SNMP traps during downtime, but how can I stop sending SNMP traps while host/service is flapping.
Well I edited my code
Code: Select all
/usr/local/nagiosxi/html/includes/components/snmptrapsender/snmptrapsender.inc.php at line number 457 by trying to get the macro by $metaPlease help me to sort this out.