News:

We really need your input in this questionnaire

Main Menu

Delay alarms

Started by ArnaHud, April 16, 2015, 03:47:39 PM

Previous topic - Next topic

ArnaHud

Hi there !
First of all, congrats for your awesome application, NetXMS is great  :)

Now for my question : I'd like to delay the notification when a node is down, but i seem to do something wrong, I don't find how to do it.
In my case, I want to receive a mail notification when a node is down for like 5min (because sometime, the equipment just has some trouble to get the Wifi and get disconnected for a few seconds to one minute, and I don't want to be alerted for that).
The mail notification is working, but it's send just 1-2 min after the node goes down ...
Is there an option I'm missing to do that ? Or do I need to do some scripting for this ?

Thanks !

Victor Kirhenshtein

Hi,

there are few different options available. Simpler one is to set "required poll count" option on node interfaces to number of polls needed to consider interface down. So of you have set it to 2 for example, server will consider interface (and node) as down if it will not respond for two consecutive status polls (once per minute by default).

Best regards,
Victor

ArnaHud

Hi,
Thanks for your answer.
But with this solution, I have to set the "required poll count" of every node interfaces to the number I want, that's a bit long ...
Is there a quicker solution to do it, for example for a whole Infrastructure Services Group or a Template ?
I'd like to do this on all my servers and switches.

Thanks !

tomaskir

You can either set it globally in Server Configuration Variables under "PollCountForStatusChange" (requires server restart).

Or you can set it per-interface.

ArnaHud

#4
Ah yes, i didn't see this, thank you !
Once I have changed this value (for 5), will NetXMS see the change of state immediately (in the last values of the status agent of a node), or the values will change after the "PollCountForStatusChange" ?
It could be awesome, like that I could see if a node interface was done for a poll status, but was up the next one (it could be just a restart or a signal lost and I don't need to receive a mail for this one).
I don't know if I'm clear with this  :P

Edit : I just tried this solution, it's working, but not totally as I want. I'd like to have the node down in the NetXMS console after the first poll status, but receive a mail if he's down for 5 min (after 5 polls status down).
Here the state change just after 5 min, so in this period of time, I don't see it down (it takes 5 polls to tell me that the node is down, and 5 new polls for up where I'd like to know at the first poll that he's up ^^).

Victor Kirhenshtein

Hi,

then solution could be different. You can leave poll count for status change at 1, and create script based DCI which will return 1 if node is down and 0 if not. Then you can create threshold which will fire if value is 1 for at least 5 polls, and send notification based on that threshold's event. Script could be like this:


return ($node->runtimeFlags & 0x0004) ? 1 : 0;


More information about Node class can be found here: https://wiki.netxms.org/wiki/NXSL:Node.

Best regards,
Victor

ArnaHud

#6
If I'm not mistaking, I have to put this script in the "Transformation" of my DCI ?
But for the second part, I don't see how to say at least 5 polls in my threshold ... Is it with an "Operation >= 5" and the "Last polled value" at 1 ?
Sorry for my "noob" questions, I have a bit of trouble on this as you can see  :-[

Edit : Nevermind, I think I just understood my mistake ... In the threshold panel, I thought "Last Polled Value" was like the last value returned, and in fact it's the duration, the number of polls ... So in my case "Last polled value" at 5 and "Operation == 1".

ArnaHud

Hi,
After more tests, it seems to work perfectly with your method Victor.
Thank you very much for your time !

NicovdWalt

Good day,

I have this delay on message working on nodes that is on the same network and it works 100% but battling to get it working on nodes that has it polling on a network service.
Any help with the code the adjustments in the script would be greatly appreciated!

Thank you!

Victor Kirhenshtein

Hi,

please share your configuration - maybe I'll spot the error.

Best regards,
Victor