[mrtg] Need accurate cpu % info using net-snmp and mrtg
Michael Cunningham
crayola at optonline.net
Wed Mar 12 02:42:22 MET 2003
Help!:)
Based on the example (http://net-snmp.sourceforge.net/tutorial/index.html)
on the net-snmp webpage I setup mrtg to graph cpu usage
on a Sun E6500 running Solaris 2.6. and net-snnpd.
I am looking to get the following stats from the system
using the UCD mibs.
1. Active cpu usage %
2. Kernel % versus Wait %
3. User % versus System %
For number 1, I am adding up the responses from
ssCpuRawSystem, ssCpuRawKernel, ssCpuRawWait, and ssCpuRawUser.
And mrtg is dividing by the polling interval (like mrtg normally does).
This should show all active cpu usage minus idle time (ssCpuRawIdle).
LoadMIBS: /usr/local/share/snmp/mibs/UCD-SNMP-MIB.txt
Target[aladar.cpu]:ssCpuRawUser.0&ssCpuRawUser.0:public at aladar +
ssCpuRawSystem.
0&ssCpuRawSystem.0:public at aladar +
ssCpuRawWait.0&ssCpuRawWait.0:public at aladar +
ssCpuRawKernel.0&ssCpuRawKernel.0:public at aladar
MaxBytes[aladar.cpu]: 100
Unscaled[aladar.cpu]: ymwd
ShortLegend[aladar.cpu]: %
YLegend[aladar.cpu]: CPU Utilization
Options[aladar.cpu]: growright,nopercent,noinfo
Unfortunatly it appears that the numbers returned from
net-snmpd are not usage info but raw kernel time ticks.
Thus all my numbers are WAY off from reality.
I learned this from reading an email in the net-snmpd archive regarding
"laLoadinit and ssCpuRaw* problems" on 3/5/03
http://sourceforge.net/mailarchive/forum.php?thread_id=1786657&forum_id=4959
Is there anyway to convert these ticks to usage info?
The email said I should divide by a number but the number is
platform dependant.. any idea what this number is on
solaris 2.6, 7, and 8? Any other way to get accurate
cpu usage info using net-snmpd, mrtg, and the UCD mib
in perticular?
Thanks for your assistance...
Mike
--
Michael Cunningham (CISSP, SCNA, SCSA, CCSA)
--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive http://www.ee.ethz.ch/~slist/mrtg
FAQ http://faq.mrtg.org Homepage http://www.mrtg.org
WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
More information about the mrtg
mailing list