[mrtg] OIDs for Cisco 7613, 7609 & CRS-1

McDonald, Dan Dan.McDonald at austinenergy.com
Mon Apr 13 14:52:20 CEST 2009


On Sat, 2009-04-11 at 17:09 +0200, Simon Leinen wrote:
> Mick  writes:
> > On Saturday 11 April 2009, Kashif Siddiq Patoli wrote:

> For RP CPU readings, you could use OLD-CISCO-SYS-MIB::avgBusy5.0
> (1.3.6.1.4.1.9.2.1.58.0).  If you want to access all CPUs (RP, SP,
> DFCs), use CISCO-PROCESS-MIB::cpmCPUTotal5minRev
> (1.3.6.1.4.1.9.9.109.1.1.1.1.8)

That's probably correct.  Cisco has wavered a bit on support of the Rev
variants, so it might be cpmCPUTotal5min instead.  Depends on the
versions of code involved.

> DOM/transceiver monitoring values such as optical Tx and Rx power can be
> accessed using CISCO-ENTITY-SENSOR-MIB, in particular entSensorValue
> (1.3.6.1.4.1.9.9.91.1.1.1.1.4).  The indexing is somewhat tricky because
> it refers to the highly structured SENSOR-MIB.

Not all optics produce this value, but for those that do this is a very
interesting thing to monitor.  It's also somewhat annoying in that it is
reported as a negative number, in centiBels.  To support the negative
numbers, you have to perform an rrdtool tune on the .rrdfiles - Someday
I'll write that into cfgmaker...  

I wrote a template to perform the indexing and change the unit to
deciBels.  It's posted on Steve Shipway's site.  The salient portion is:
#
# Look for dBm meters - probably interesting

snmpMIB_to_OID("/usr/share/snmp/mibs/ENTITY-SENSOR-MIB.my");
snmpMIB_to_OID("/usr/share/snmp/mibs/CISCO-ENTITY-SENSOR-MIB-V1SMI.my");
     my (@est) = snmpwalk($router,$v3opt,'entSensorType');
   foreach my $esti (@est) {
        my ($tinstance,$ttype) = ($esti =~  /(\d+):(.+)$/) ;
   next if $ttype != 14;
      my (@estv) = snmpwalk($router,$v3opt,'entSensorThresholdValue.'.$tinstance);
      my %thresh;
      foreach my $estvi (@estv) {
         my ($thin,$value) = ($estvi =~ /(\d+):(.+)$/) ;
         $thresh{$thin} = $value;
         };
      my $maxsize = $thresh{1}+10;
      my ($sens_name) = snmpget($router,$v3opt,'entPhysicalName.'.$tinstance);
   my $sens_descr .= ' '.$sens_name;
   my $target_name=$router_name.".signal".$tinstance;
   $target_lines .= <<SIGNAL
#--------------------------------------------------------------------------------------
# Signal Strength
    
Target[$target_name]: entSensorValue.$tinstance&entSensorValue.$tinstance:$router
SnmpOptions[$target_name]: $v3options
YLegend[$target_name]: dB
Options[$target_name]: gauge, noi, nopercent
Directory[$target_name]: $directory_name
MaxBytes[$target_name]: $maxsize
ShortLegend[$target_name]: dB
Factor[$target_name]: .1
routers.cgi*ShortDesc[$target_name]: $sens_name
routers.cgi*Options[$target_name]: nototal
bb*host[$target_name]: $router_name
bb*svc[$target_name]: signal
bb*red[$target_name]: $thresh{4}:$thresh{1}
bb*yellow[$target_name]: $thresh{3}:$thresh{2}
Legend1[$target_name]: dB
WithPeak[$target_name]: ymw
Title[$target_name]: $sysname $sens_descr
PageTop[$target_name]: <H1>$sysname $sens_descr </H1>
<TABLE>
   <TR><TD>System:</TD><TD>$sysname  </TD></TR>
   <TR><TD>Location:</TD><TD>$syslocation </TD></TR>
</TABLE>
SIGNAL
;
}
> 
> The temperatures could also be retrieved using entSensorValue,

So, the code above could be re-used, just change the 
        next if $ttype != 14;
line to whatever ttype is used for the temperature monitors, then change
labels and units to match.


-- 
Daniel J McDonald, CCIE #2495, CISSP #78281, CNX
Austin Energy
http://www.austinenergy.com

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
Url : http://lists.oetiker.ch/pipermail/mrtg/attachments/20090413/d1581bbc/attachment-0001.bin 


More information about the mrtg mailing list