Xymon Mailing List Archive search

CPU Utilization Not Correct or Averaging

5 messages in this thread

list James Wade · Fri, 8 Dec 2006 11:27:23 -0600 ·
We have a couple other monitoring tools here

in-house; although Hobbit is catching on more.

 
I've had questions about CPU Utilization, The charts

don't seem to correlate with the other two monitoring

tools. As an example, The other tools show CPU

Utilization at 80% during a couple hours at night,

and Hobbit shows 26% Utilization. 

 
Both the other Tools show 80% utilization during those

hours, but Hobbit doesn't.

 
I looked into this once before, and I know it depends on

how the data sampling is being done. 

 
Any ideas on this would be helpful.

 
Thanks.James
list Rich Smrcina · Fri, 08 Dec 2006 11:30:32 -0600 ·
If the other tools are using their own functions to get the utilization, it could show much different values than the operating system provided features that Hobbit typically uses.  The sampling interval will also make a big difference.  It's best to compare apples to apples (as much as you can).
quoted from James Wade

James Wade wrote:
We have a couple other monitoring tools here

in-house; although Hobbit is catching on more.

 
I’ve had questions about CPU Utilization, The charts

don’t seem to correlate with the other two monitoring

tools. As an example, The other tools show CPU

Utilization at 80% during a couple hours at night,

and Hobbit shows 26% Utilization.

 
Both the other Tools show 80% utilization during those

hours, but Hobbit doesn’t.

 
I looked into this once before, and I know it depends on

how the data sampling is being done.

 
Any ideas on this would be helpful.

 
Thanks…James

 
-- 

Rich Smrcina
VM Assist, Inc.
Phone: XXX-XXX-XXXX
Ans Service:  XXX-XXX-XXXX
user-61add9955ef9@xymon.invalid

Catch the WAVV!  http://www.wavv.org
WAVV 2007 - Green Bay, WI - May 18-22, 2007
list James Wade · Fri, 8 Dec 2006 11:39:13 -0600 ·
True, but managers only see graphs, two have the same
values, one doesn't....

I like Hobbit, and I want to keep it out here, so
justification wise, I'd like to make it look the
same.

I did a quick look at cpu, the load average is low,
but the high cpu utilization is coming from to much
iowait time because they are writing to NFS shares.

How does Hobbit get CPU utilization? Does it compare idle, user, kernel, iowait, swap?
(Say from Top)

So for example, utilization might be 100 - idle time.
and take samplings from idle time?

Thanks ... James
quoted from Rich Smrcina

-----Original Message-----
From: Rich Smrcina [mailto:user-cf452ff334e0@xymon.invalid] Sent: Friday, December 08, 2006 11:31 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] CPU Utilization Not Correct or Averaging

If the other tools are using their own functions to get the utilization, it could show much different values than the operating system provided features that Hobbit typically uses.  The sampling interval will also make a big difference.  It's best to compare apples to apples (as much as you can).

James Wade wrote:
We have a couple other monitoring tools here

in-house; although Hobbit is catching on more.

 
I've had questions about CPU Utilization, The charts

don't seem to correlate with the other two monitoring

tools. As an example, The other tools show CPU

Utilization at 80% during a couple hours at night,

and Hobbit shows 26% Utilization.

 
Both the other Tools show 80% utilization during those

hours, but Hobbit doesn't.

 
I looked into this once before, and I know it depends on

how the data sampling is being done.

 
Any ideas on this would be helpful.

 
Thanks.James

 
-- 
Rich Smrcina
VM Assist, Inc.
Phone: XXX-XXX-XXXX
Ans Service:  XXX-XXX-XXXX
user-61add9955ef9@xymon.invalid

Catch the WAVV!  http://www.wavv.org
WAVV 2007 - Green Bay, WI - May 18-22, 2007
list Tom Georgoulias · Fri, 08 Dec 2006 16:25:34 -0500 ·
quoted from James Wade
James Wade wrote:
I did a quick look at cpu, the load average is low,
but the high cpu utilization is coming from to much
iowait time because they are writing to NFS shares.
Not the problem at hand, but you shouldn't suffer that kind of CPU wait unless you are exceeding the capacity of the disk IO on your NFS server, have network issues, or something else.  Worthy of more attention if you have the time.
quoted from James Wade
How does Hobbit get CPU utilization? Does it compare idle, user, kernel, iowait, swap?
(Say from Top)

So for example, utilization might be 100 - idle time.
and take samplings from idle time?
CPU utilization is that:  100 - cpu idle time, as measured by the output of vmstat.  Some versions of vmstat report CPU utilization through 4 parameters: user, system, idle, CPU IO wait, others lump iowait and system into a single parameter.

Are the other tools getting their data from vmstat (or sar, etc.)? Personally, I would try watching the server during those timeframes with something like "vmstat 2" and see/understand for myself what is happening.  If it happens at odd hours, just cron a little script and analyze the data in the morning.  Once you have an idea of what you saw, you can figure out which reporting tool is giving valid results.

Tom
-- 
Tom Georgoulias
Systems Engineer
McClatchy Interactive
list Henrik Størner · Fri, 8 Dec 2006 22:40:57 +0100 ·
quoted from James Wade
On Fri, Dec 08, 2006 at 11:27:23AM -0600, James Wade wrote:
I've had questions about CPU Utilization, The charts
don't seem to correlate with the other two monitoring
tools. As an example, The other tools show CPU
Utilization at 80% during a couple hours at night,
and Hobbit shows 26% Utilization. 
Make sure you understand what you're looking at. I assume you are
comparing the CPU utilisation from the vmstat data - the one on the
trends page, NOT the "CPU load" graph found on the "cpu" status page.
The "CPU load" graph shows the "5 minute load average", which has
nothing to do with CPU utilisation, but is a measure of how many tasks
are queuing up for the scheduler to allocate it some CPU time.

If you are looking at the vmstat graph, then by default you'll get
the plain "vmstat" graph which includes the time vmstat counts as
"system", "user" and "idle" time. Some systems also have an "I/O wait"
state; this is included in the "vmstat1" graph. Nightly jobs sound like
backups, these would show a high percentage of time in I/O wait state
which doesn't show up on the default vmstat graph. You can switch the
default graph by putting a "TRENDS:*,vmstat:vmstat1" on this host's
entry in the bb-hosts file.
quoted from James Wade
Both the other Tools show 80% utilization during those
hours, but Hobbit doesn't.
Hobbit uses vmstat to collect these data from Unix systems - the command
"vmstat 2 300" specifically. I must admit I trust the built-in OS
commands to return valid data, more than I trust another monitoring tool 
whose method of determining these data I do not know.


Regards,
Henrik