Clustering with SNMP Proxy

Started by Sumit Pandya, November 11, 2010, 08:06:34 AM

Previous topic - Next topic

Victor Kirhenshtein

Yes, it must be named "Dummy". This is what I wrote in my previous message:

Quote from: Victor Kirhenshtein on December 07, 2010, 09:52:00 AM
You can create additional DCI with source "Internal" and name "Dummy" (of course description can be any).

You can change description of the DCI, but not the name. Description is a free form text intended to be read and understand by humans, but name is a parameter's identifier understandable by server and/or agents. "Internal" origin means that values for these parameters generated by NetXMS serer itself, without asking any external entities. One of supported internal parameters is named "Dummy", and it always returns 0 when polled for value. It was added specifically for providing "ticks" for calculated DCIs.

So it is not a "workaround", it's just correct system configuration :)

Best regards,
Victor

Sumit Pandya

Quote from: Victor Kirhenshtein on December 09, 2010, 02:50:50 PM
Yes, it must be named "Dummy". This is what I wrote in my previous message:

Quote from: Victor Kirhenshtein on December 07, 2010, 09:52:00 AM
You can create additional DCI with source "Internal" and name "Dummy" (of course description can be any).
My mistake to overlook that "Quotation"  :o though "Quotation" is my practice as well.

Quote from: Victor Kirhenshtein on December 09, 2010, 02:50:50 PM
So it is not a "workaround", it's just correct system configuration :)
I'm indded sorry for that unusual term. However I's not only pointing about this "Dummy" problem. I've co-related all my experience with NetXMS, like Cluster node disapper, OS hang without n/w, etc. For this "Dummy", if you cannot allow any other name then can't it make some select-only/drop-down type input there?

Finally Yes, this thread can be closed but this has something to go into Mantis

Sumit Pandya

Can I create DCI for dummy summary node with help of Array as below?
array monitornodes;
monitornodes = {"system-1" , "system-2", "system-3"};
summary=0;
for (i=1; monitornodes != NULL ; i++)
{
  inode = FindNodeObject($node, monitornodes);
  ivalue = GetDCIValue(inode, FindDCIByDescription(inode, "TotalAuth"));
  summary = summary + ivalue;
}
return summary;

I see array initialization is not been supported as above syntax. However I get success with below syntax
array monitornodes;
monitornodes[1] = "system-1";
monitornodes[2] = "system-2";
monitornodes[2] = "system-3";

My point of asking is primary about array initialization syntax.

Victor Kirhenshtein

Hi!

The only possible initialization of array is like

monitornodes[1] = "system-1";
monitornodes[2] = "system-2";
monitornodes[2] = "system-3";

I like the idea of having array initializers, I will add it to NXSL. Also, your script has an error if for loop condition - it should be monitornodes != NULL, not monitornodes != NULL. So, correct version of the script should looks like this:


array monitornodes;

monitornodes[1] = "system-1";
monitornodes[2] = "system-2";
monitornodes[2] = "system-3";

summary=0;
for (i=1; monitornodes[i] != NULL ; i++)
{
  inode = FindNodeObject($node, monitornodes[i]);
  ivalue = GetDCIValue(inode, FindDCIByDescription(inode, "TotalAuth"));
  summary += ivalue;
}

return summary;


Best regards,
Victor