Discussion:
Monitor Temperature
Stefan Reinke
2012-03-14 05:53:59 UTC
Permalink
Stefan Reinke [http://community.zenoss.org/people/Stefan] created the discussion

"Monitor Temperature"

To view the discussion, visit: http://community.zenoss.org/message/65175#65175

--------------------------------------------------------------
Good day,

I am trying to monitor temperatures of my servers, so that I can know when the aircon goes down in the server room.

What I have done, is installed lm-sensors on my of my servers, and used the OID value to retrieve the temp in C of one of the cpu cores.

When I create a snmp data source in Zenoss under the server I get the following:


Preparing Command...
Executing command snmpwalk -cpublic -v1 192.168.2.172 iso.3.6.1.4.1.2021.13.16.5.1.3.9 against 192.168.2.172
UCD-SNMP-MIB::ucdExperimental.16.5.1.3.9 = Gauge32: 39000

I read somewhere that the value that should be printed should be a integer, will Gauge be fine? And also is there anyway that I can take away the three 0's at the end, because at the moment zenoss will not graph this. The datapoint only reports as nan.

Just a little more information, the name of the SNMP is : iso.3.6.1.4.1.2021.13.16.5.1.3.9, so the data point is the same (iso.3.6.1.4.1.2021.13.16.5.1.3.9).

Hope someone can help me.

Regards,
Stefan
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/65175#65175]

Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
Andrea Consadori
2012-03-14 06:57:48 UTC
Permalink
Andrea Consadori [http://community.zenoss.org/people/andrea.consadori] created the discussion

"Re: Monitor Temperature"

To view the discussion, visit: http://community.zenoss.org/message/65159#65159

--------------------------------------------------------------
maybe exist a better way but when i've to play with value grabbed from snmp sometimes (for example if i've a mix of number and value) i add datasource as script and i execute /sbin/snmpwalk + sed options,

i.e.
/usr/bin/snmpwalk -${device/zSnmpVer} -c${device/zSnmpCommunity} ${here/manageIp}   private | grep 14988.1.1.1.1.1.3 | tail -c 9 | sed -e 's/.*/temp:&/'
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/65159#65159]

Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
Stefan Reinke
2012-03-14 10:21:02 UTC
Permalink
Stefan Reinke [http://community.zenoss.org/people/Stefan] created the discussion

"Re: Monitor Temperature"

To view the discussion, visit: http://community.zenoss.org/message/65179#65179

--------------------------------------------------------------
Hi Andrea,

Took your advice, went with the following command in the end:

`snmpwalk -c public -v 1 192.168.2.172 iso.3.6.1.4.1.2021.13.16.5.1.3.9 -Oqv`

Gives me the temparature, which I then parse and divide to give me the correct value I want.

All done in a bash script.
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/65179#65179]

Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
jcurry
2012-03-14 10:55:48 UTC
Permalink
jcurry [http://community.zenoss.org/people/jcurry] created the discussion

"Re: Monitor Temperature"

To view the discussion, visit: http://community.zenoss.org/message/65181#65181

--------------------------------------------------------------
Hi Stefan,
For starters, your gauge should be fine - it is simply a form of integer.

Looking at the LM-SENSORS-MIB which is providing your data, it looks like iso.3.6.1.4.1.2021.13.16.5.1 gets you into the table for lmMiscSensors, and the .3 after that is the OID for the value.  The interesting part is your .9 on the end - where did you get this from??  lmMiscSensors is a table which provides values (potentially) for a numer of instances (ie lots of similar sensors).  For some reason, you are using the 9th instance.

The reason you are getting nan values is not because of the three 0s but because your OID isn't quite right.  If the data you are requesting is tabular then you don't want the last .9 on the OID of your datapoint - Zenoss will do that for you.

If you then want to graph values such as 39, rather than 39000, you can fix that in the definition of the graph point by using an RPN (Reverse Polish Notation) expression of 1000,/   (ie divide by 1000).  You can see en example of an RPN in the standard /Server/Linux Device template - look at the LoadAverage Graph definition and drill into the laLoadInt5 Graph Point definition.

Cheers,
Jane
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/65181#65181]

Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
jmp242
2012-03-14 11:59:44 UTC
Permalink
jmp242 [http://community.zenoss.org/people/jmp242] created the discussion

"Re: Monitor Temperature"

To view the discussion, visit: http://community.zenoss.org/message/65162#65162

--------------------------------------------------------------
Also as a slightly different solution, the minigoose / weathergoose tools are reasonably priced and basic templates work with the weathergoose zenpack in 3.x... And will then give ambient temps rather than CPU temps...

--
James Pulver
ZCA Member
LEPP Computer Group
Cornell University
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/65162#65162]

Start a new discussion in zenoss-users by email
[discussions-community-forums-zenoss--***@community.zenoss.org] -or- at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
Loading...