Situation
-
Hi,
i have to create a situation in which when an interfaces goes down, no alarm is sent for the relative node down.
I have to do this for many interfaces and many nodes.
I use the procedure exposed in NetXms Manual, but i have a doubt for the filtering script.
Suppose we have node A with interface A and node B with interface B.
I use a general script like this (in the template "show alarm when node is down")
sub main()
{
s = FindSituation("ServiceStatus", %n);
if (s != NULL)
{
if (s->status == "failed")
return false; // Don't match rule
}
return true; // Match rule
}and in "show alarm when interfaces is down" i set this value:
Situations object:ServiceStatus
Instance:%n
and in Attributes:
name=status
value=failed.Can i use the previous general script or i Have to create specific script like the following?
in "show alarm when node is down" set source=nodeA and insert the following script:
sub main()
{
s = FindSituation("ServiceStatus", InterfaceA);
if (s != NULL)
{
if (s->status == "failed")
return false; // Don't match rule
}
return true; // Match rule
}and in "show alarm when interface is down" set source= interface A and situations:
Situations object:ServiceStatus
Instance:InterfaceA
and in Attributes:
name=status
value=failed.(obviously i repeat this procedure for interface B and node B).
Thank you for help.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login