So you got a APC environment monitor (NetBotz) and you want XYMON / Hobbit / BB to monitor and alert if your tempature is rising? Funny me too.
I spent several hours trying to get a VB script to built to do this and I am just not a big fan of VB. So being a Perl plucker I desided to write one in Perl and share it with everyone.
Here is what it does:
The script queries via SNMP the OID for the tempature sensors current state and then create a XYMON file and place it in the tmp folder where XYmon(BBWin) resides so that the XYMON(BBWin) service can pick it up and transmit the information to the BBDisplay.
Prereqs are: Windows host, BBWin, ActiveState Perl 5 installed on windows, snmpget.exe application located at http://www.snmpsoft.com/freetools/snmpget.html
Place SNMPGET.EXE in an area that is seen by Windows PATH.
Add to BBWin.cfg under the <Externals> area of XML:
<load value=”C:\Perl\bin\perl.exe netbotz.pl” timer=”5m” />
and copy this script to the BBWin/Bin directory. Every 5 minutes you should see a “NetBotz” file created in BBWin/tmp and shortly afterwards BBwin will remove file once data is sent. On your BBDisplay you should get a new column called [NetBotz] and when you select the “Dot” it will display the current temp.
You may need to play with the OID # for your install of Netbotz as mine had 8 ports (OID’s) for tempature monitors but we only used 1 port so I am only monitoring that OID.
OID’s are
1.3.6.1.4.1.318.1.1.10.4.2.3.1.5.0.1
through
1.3.6.1.4.1.318.1.1.10.4.2.3.1.5.0.14
So adjust the last digits (1-14) for your sensor location on Netbotz.
Download -> Netbotz Perl script
Enjoy Shannon, aka Cubert