This is a discussion on Re: AW: Calculationg CPU usage using ssCpuRawIdle within the SNMP Users forums, part of the Networking and Network Related category; This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools. --1078299942-2016769622-1115877764=:3693 Content-Type: TEXT/PLAIN; CHARSET=UTF-8; FORMAT=flowed Content-Transfer-Encoding: 8BIT Content-ID: <Pine.LNX.4.62.0505112307311.3693@mulva.they.org > On Wed, 11 May 2005, Mohr James wrote: > Date: Wed, 11 May 2005 20:42:54 +0200 > From: Mohr James <james.mohr@elaxy.com> > To: net-snmp-users@lists.sourceforge.net > Subject: AW: Calculationg CPU usage using ssCpuRawIdle > >>> -----Ursprüngliche Nachricht----- >>> Von: frank [mailto:ratty@they.org] >>> Gesendet: Dienstag, 26. April 2005 23:59 >>> An: Mohr James >>> Cc: net-snmp-users@lists.sourceforge.net >>> Betreff: Re: Calculationg CPU usage using ssCpuRawIdle > <SNIP> > >>> Tho since then, I've abandoned that method. Instead I use a >>> small perl >>> script called by SNMP's "exec" handler. The script runs vmstat for 2 >>> cycles and reaps the percentages listed (from the second >>> line) without any >>> extra math being done. > <SNIP> > > I am curious about the mechanics of how you actually get the data. Do you do the walk once, reading it into an array then parse the array? Or do you do the walk twice, calculating the offset into the table the first time and the do the walk again to get the data? > > When is the command actually run? It seems to me when the walk reaches UCD-SNMP-MIB::extOutput.1, or so it seems. > > Thanks for the help! > > Regards, > > Jim Mohr > Sure, take a look at http://web.they.org/software/check_local_cpu.pl snmpd.conf has: exec .1.3.6.1.4.1.1.1 cpu /path/to/check_local_cpu.pl Then I can run: snmpget localhost .1.3.6.1.4.1.1.1.101.1 And I get back: SNMPv2-SMI::enterprises.1.1.101.1 = STRING: "u:2,s:1,i:98" which is easy for me to parse and stuff into an RRD or whatever. hope this helps -frank --1078299942-2016769622-1115877764=:3693-- ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7393&alloc_id=16281&op=click _______________________________________________ Net-snmp-users mailing list Net-snmp-users@lists.sourceforge.net Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/...net-snmp-users |