Sending Multiple Emails

Started by pdelvaglio, March 11, 2016, 06:48:44 PM

Previous topic - Next topic

pdelvaglio

We are trying to setup a configuration where if any of our nodes are down it will send an email at first poll and then at 5 minutes if it is still down and then at 20 minutes if it is still down.  We only care about icmp at this point.

Can this be setup globally so each node doesn't have to be configured individually?

Any help is appreciated.

Thanks.

pdelvaglio

From reviewing other forum posts it seems like I need to:

1. Create a custom event such as "NODE_STILL_DOWN"
2. Create a server script that runs nxevent calling NODE_STILL_DOWN.
3. Add an action to "SYS_NODE_DOWN" that runs the above server script.
4. Create a processing policy rule for NODE_STILL_DOWN that has a filter checking for 5 and 20 minute poll intervals.


Is this the best way to do this?

If so,  how can I call nxevent from a server script? (I haven't seen any examples.  I am using Windows NetXMS).  nxevent.exe is in C:\NetXMS\bin on the server.

Thanks for any help.

Victor Kirhenshtein

Hi,

if you are running server scripts (NXSL), you can use PostEvent function: https://wiki.netxms.org/wiki/NXSL:PostEvent

Another possible option is to set node's custom attribute in reaction for SYS_NODE_DOWN and create status poll hook script, which will check if node is down for certain amount of time and use PostEvent function to generate another event.

Best regards,
Victor

pdelvaglio

Thank you. Your status poll hook script suggestion works great.