Cheshire Cat Computing

Software support and information
It is currently Tue May 21, 2013 9:02 pm

All times are UTC + 12 hours [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Fri Jul 22, 2011 4:21 am 
Offline
User

Joined: Fri Jul 22, 2011 4:07 am
Posts: 2
I am trying to graph the current load on an APC AP7941 Switched PDU, and getting the SNMP readings from the PDU is no problem, but when I try and have routers2.cgi graph it, I can't get the reading to scale correctly.

For example, say I have an 11.5 amp draw on the strip, when I graph it, instead of getting it to show 11.5 amps, it shows as 115 amps, which of course would be some crazy current.

I saw where in MRTG I could use YTicsFactor to change readings, but I am guessing when coupled with RRD and Routers2, that this doesn't function, as I have tried setting this, but still my routers2 graphs show the same.

Here is a sample of what I am doing in my MRTG config:

Code:
Target[power-2-2.xxx.net]: enterprises.318.1.1.12.2.3.1.1.2.2&enterprise
s.318.1.1.12.2.3.1.1.2.3:public@power-2-2.xxx.net
Title[power-2-2.leadmon.net]: POWER-2-2
routers.cgi*ShortDesc[power-2-2.xxx.net]: PDU 2-2 Current Usage
PageTop[power-2-2.xxx.net]: <H1>POWER-2-2 </H1>
MaxBytes[power-2-2.xxx.net]: 150
Options[power-2-2.xxx.net]: gauge,growright,nopercent,integer
Ylegend[power-2-2.x.net]: Power in Amps
Shortlegend[power-2-2.xxx.net]: Amps
Unscaled[power-2-2.xxx.net]: ymwd
YTics[power-2-2.xxx.net]: 15
YTicsFactor[power-2-2.xxx.net]: 0.1



I also have BayTech strip that is also SNMP monitorable, but again the same issue. Does anyone have a working config for APC or BayTech PDU's??


Top
 Profile  
 
PostPosted: Sat Jul 23, 2011 9:23 am 
Offline
Site Admin

Joined: Tue Jul 29, 2003 11:42 am
Posts: 2921
Location: Auckland, New Zealand
Most likely, the SNMP is returning the value in tenths of a volt (as the value must be an integer).

To fix this, add ' / 10' to the end of the Target definition (space stroke space ten) which converts the value into the SI unit, volts.

Code:
Target[power-2-2.xxx.net]: enterprises.318.1.1.12.2.3.1.1.2.2&enterprises.318.1.1.12.2.3.1.1.2.3:public@power-2-2.xxx.net / 10


Note that you could also use 'Factor[]: 0.1' but this will perform the calcuation between the store and display stages (IE, Routers2 does it), whereas the first method does it between the retrieve and store phases (IE, MRTG does it). It is Best Practice to store the data in SI units, so the first method is preferable to the second.

_________________
Steve Shipway
UNIX Systems, ITSS, University of Auckland, NZ
Woe unto them that rise up early in the morning... -- Isaiah 5:11


Top
 Profile  
 
PostPosted: Sun Jul 31, 2011 3:33 pm 
Offline
User

Joined: Fri Jul 22, 2011 4:07 am
Posts: 2
Thanks Steve, worked like a charm.. As many years as I have used mrtg/rrdtool, and I never knew you could divide the result of the query..


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 12 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group