[mrtg] mac os mibs
Greg Donald
gdonald at gmail.com
Mon Apr 16 20:22:19 CEST 2007
I'm on Mac OS 10.4. I'm trying to find the correct mib to use for cpu usage:
> snmpwalk -v 1 -c public localhost | grep -i cpu
turns up nothing and everything else I've tried:
> snmpwalk -v 1 -c public localhost | grep -i proc
SNMPv2-MIB::sysORDescr.4 = STRING: The MIB for Message Processing and
Dispatching.
HOST-RESOURCES-MIB::hrSystemMaxProcesses.0 = INTEGER: 532
HOST-RESOURCES-MIB::hrDeviceType.768 = OID:
HOST-RESOURCES-TYPES::hrDeviceProcessor
HOST-RESOURCES-MIB::hrDeviceType.3072 = OID:
HOST-RESOURCES-TYPES::hrDeviceCoprocessor
HOST-RESOURCES-MIB::hrDeviceDescr.3072 = STRING: Guessing that there's
a floating point co-processor
HOST-RESOURCES-MIB::hrProcessorFrwID.768 = OID: SNMPv2-SMI::zeroDotZero
results in errors like this:
> /opt/local/bin/mrtg /etc/mrtg/cpu.cfg
Unknown SNMP var hrDeviceDescr.3072
at /opt/local/bin/mrtg line 2149
Unknown SNMP var hrDeviceDescr.3072
at /opt/local/bin/mrtg line 2149
2007-04-16 13:13:24: WARNING: Expected a number but got '22:56:53'
2007-04-16 13:13:24: WARNING: Expected a number but got 'neptune'
2007-04-16 13:13:24: ERROR: Target[localhost.cpu][_IN_] '
$target->[0]{$mode} ' did not eval into defined data
2007-04-16 13:13:24: ERROR: Target[localhost.cpu][_OUT_] '
$target->[0]{$mode} ' did not eval into defined data
My cpu.cfg currently looks like this:
> cat /etc/mrtg/cpu.cfg
WorkDir: /opt/local/apache2/htdocs/mrtg
LoadMIBs: /usr/share/snmp/mibs/UCD-SNMP-MIB.txt
Target[localhost.cpu]: hrDeviceDescr.3072&hrDeviceDescr.3072:public at localhost
RouterUptime[localhost.cpu]: public at localhost
MaxBytes[localhost.cpu]: 100
Title[localhost.cpu]: CPU Load
PageTop[localhost.cpu]: <H1>Active CPU Load %</H1>
Unscaled[localhost.cpu]: ymwd
ShortLegend[localhost.cpu]: %
YLegend[localhost.cpu]: CPU Utilization
Legend1[localhost.cpu]: Active CPU in % (Load)
Legend2[localhost.cpu]:
Legend3[localhost.cpu]:
Legend4[localhost.cpu]:
LegendI[localhost.cpu]: Active
LegendO[localhost.cpu]:
Options[localhost.cpu]: growright,nopercent
I've tried a number of different Target entries after reading mailing
list archives and Google'ng.
Is there a special mib file for Mac hardware? I didn't see anything
in /usr/share/snmp/mibs that was Mac specific. Or is there a special
Mac how-to somewhere Google doesn't know about?
My traffic graphs looks great, but I also want CPU, memory, and load :(
Thanks up front,
--
Greg Donald
http://destiney.com/
More information about the mrtg
mailing list