Results 1 to 2 of 2
Hi
Is there a way to get the CPU load average statistics from a user-space program directly, (i.e., a function call instead of reading /proc/loadavg or parsing 'uptime' output)?
I ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 03-31-2009 #1Just Joined!
- Join Date
- Oct 2006
- Posts
- 25
CPU Load Average Stats from Kernel?
Hi
Is there a way to get the CPU load average statistics from a user-space program directly, (i.e., a function call instead of reading /proc/loadavg or parsing 'uptime' output)?
I noticed that the kernel provides task level statistics using getrusage() and I wondered if there is some support for CPU load averages as well.
Thanks,
--b
- 04-03-2009 #2Linux Enthusiast
- Join Date
- Aug 2006
- Location
- Portsmouth, UK
- Posts
- 539
You probably want "sar" which is part of the sysstat package.
RHCE #100-015-395
Please don't PM me with questions as no reply may offend, that's what the forums are for.


Reply With Quote
