Custom Script Scheduler in NNMi to make more intelligent monitoring

Idea ID 2838821

Custom Script Scheduler in NNMi to make more intelligent monitoring

Hello Micro Focus & Community 😉

In some monitoring scenarios it's required to first snmpwalk a specific OID to get the instance number to the next snmpget I need to do in order to get the correct values I need.
And after that I might need to do some math on the collected values

Currently NNMi can't do this. So this Idea is to get NNMi to be able to do this:
Call it more intelligent SNMP monitoring.

Use Case:

So for some specifc RSA servers we have been asked to monitor the license usage,

To get the current used licenses we must collect the following OID:
.1.3.6.1.4.1.2197.20.24.1.2.216 = STRING: "45372"
That’s the easy part

 

To get the total number of licenses we need to do:

First get the Users licenses instance numbers:

snmpwalk -v 2c -c public myRSAnode .1.3.6.1.4.1.2197.20.20.1.6 -On|grep Users

.1.3.6.1.4.1.2197.20.20.1.6.2 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.9 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.12 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.19 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.34 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.41 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.48 = STRING: "Users"
.1.3.6.1.4.1.2197.20.20.1.6.51 = STRING: "Users"

As showed in the above walk there are multiple licenses files loaded. I need to get the Users by doing a grep for the Users part.

After we have located the instance numbers we need to collect how many licenses each lincese file have:

.1.3.6.1.4.1.2197.20.20.1.7|grep "1\.7\.2\s\|.\.7\.9\s\|1\.7\.12\s\|1\.7\.19\s\|1\.7\.34\s\|1\.7\.41\s\|1\.7\.48\s\|1\.7\.51\s"

.1.3.6.1.4.1.2197.20.20.1.7.2 = STRING: "37505"
.1.3.6.1.4.1.2197.20.20.1.7.9 = STRING: "1000"
.1.3.6.1.4.1.2197.20.20.1.7.12 = STRING: "1000"
.1.3.6.1.4.1.2197.20.20.1.7.19 = STRING: "2000"
.1.3.6.1.4.1.2197.20.20.1.7.34 = STRING: "2000"
.1.3.6.1.4.1.2197.20.20.1.7.41 = STRING: "1000"
.1.3.6.1.4.1.2197.20.20.1.7.48 = STRING: "1000"
.1.3.6.1.4.1.2197.20.20.1.7.51 = STRING: "1000"

The grep in this scenario is due to I not want to make a snmpget manual.
Then we need to summarize the numbers returned here to get the total number of licenses on the system = 46505:

To calculate the total number of available licenses: total – current usage:
46505 – 45372 = 1133

I ofcause need to graph it all

  • Total Licenses
  • Uses Licenses
  • Available Licenses

Solution example:

Since this is a complicated calculation, and collection for reporting, a solution could be a script based monitoring schedular in NNMi, that accepts return values in, Integer, boolen, gauge or strings (like default SNMPGET commands does, and then able to enable NNMi to add the collected data to NPS/COSO data, same way as custom collection, just custom script that returns the same kind of values as the custom poller values:

  • Gauge
  • Percent
  • Counter
  • Integer
  • String 
  • Unset

The rule in such a script based monitoring would be to report back the above kind of data. It could be like:

  • Single keybased value: Total License = 46505
  • an array of multiple values: [Total License = 46505 , Used Licenses = 45372 , Available License = 1133]
  • A JSON value:
    {
        "values":
            {
                "Total Licenses": 46505,
                "Used Licenses": 45372,
                "Available License": 133
            }
        }

This would really open up NNMi to be cable of way more intelligent monitoring 😊
Specially the option to walk multiple OID's to get the values we need. Also I do know that this is for some more experienced users, but it's really needed.

 

Br 
Jan P. Madsen

 

 

2 Comments
Micro Focus Expert
Micro Focus Expert
Status changed to: Waiting for Votes

The idea has received an initial review to ensure adherence to our idea submission and community guidelines. More information may be needed at this stage, and we expect the community to help prioritize the idea with comments and community support (votes/kudos).

Fleet Admiral
Fleet Admiral

Dear

This can be easily achieved if you have Ops Bridge with OA agent and using schedule policy which calls snmpwalk to store the data to OA agent datasource and you can push the data to COSO/BVD.

The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.