Re: AW: Calculationg CPU usage using ssCpuRawIdle

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 ...


Go Back   Usenet Forums > Networking and Network Related > SNMP Users

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-12-2005
frank
 
Posts: n/a
Default Re: AW: Calculationg CPU usage using ssCpuRawIdle

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
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:20 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0