Inconsistent CPU Usage from sar & top

Claude Lindo clindo at fsl.org.jm
Tue Jun 19 19:21:11 UTC 2007


Thanks Richard,

One problem though: the server that I took this sample from is not an
SMP machine and so the command will not run...

Claude.

On Tue, 2007-06-19 at 15:01 -0400, Richard Riley wrote:
> I have encountered the same thing on a couple of my machines.  I found
> that if I run "sar -P ALL" it shows utilization per CPU with realistic
> utilization numbers.  This seems to only happen on some new Dell
> machines.  Have yet to figure out why.  Hopefully someone will have an
> answer for both of us.
> 
> Richard
> 
> > -----Original Message-----
> > From: redhat-sysadmin-list-bounces at redhat.com [mailto:redhat-
> > sysadmin-list-bounces at redhat.com] On Behalf Of Claude Lindo
> > Sent: Tuesday, June 19, 2007 2:21 PM
> > To: redhat-sysadmin-list at redhat.com
> > Subject: Inconsistent CPU Usage from sar & top
> > 
> > Hi,
> > 
> > I use both sar and top to monitor system resource utilization my
> > RHEL 4
> > servers, but I notice that they report different CPU statistics for
> > the
> > same time period, e.g:
> > > sar 1 5
> > 17:00:01 CPU %user %nice %system %iowait %idle
> > 17:00:02 all 20.00 0.00   5.00   75.00  0.00
> > 17:00:03 all 22.00 0.00   6.00   72.00  0.00
> > 17:00:04 all 15.00 0.00   9.00   76.00  0.00
> > 17:00:05 all 13.00 0.00   5.00   82.00  0.00
> > 17:00:06 all  7.00 0.00   3.00   90.00  0.00
> > Average: all 15.40 0.00   5.60   79.00  0.00
> > 
> > > top
> > top - 17:00:07 up 13 days, 9:56, 22 users, load average: 0.95, 0.88,
> > 0.91
> > Tasks: 176 total, 2 running, 173 sleeping, 0 stopped, 1 zombie
> > Cpu(s): 8.1% us, 11.8% sy, 0.0% ni, 75.5% id, 4.4% wa, 0.1% hi, 0.1%
> > si
> > 
> > PID    USER   PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
> > 3267  informix 17 0 3052 1176 748 S 11.1 0.2 6:46.73 top
> > 14729 root     16 0 2736 896  660 R  3.7 0.2 0:00.05 top
> > 2656 informix  15 0 213m 166m 165m R 1.9 33.0 535:39.68 oninit
> > 2660 root 15 0 213m 141m 141m S 1.9 28.1 43:36.36 oninit
> > 1 root 16 0 1788 516 460 S 0.0 0.1 0:05.61 init
> > 2 root 34 19 0 0 0 S 0.0 0.0 0:00.18 ksoftirqd/0
> > 3 root 5 -10 0 0 0 S 0.0 0.0 0:00.11 events/0
> > 
> > This happens on several servers and across time periods. The two
> > utils
> > report different CPU usage stats; which one is correct or is it that
> > I
> > am using them incorrectly?
> > 
> > Claude.
> > 
> > --
> > redhat-sysadmin-list mailing list
> > redhat-sysadmin-list at redhat.com
> > https://www.redhat.com/mailman/listinfo/redhat-sysadmin-list
> 




More information about the redhat-sysadmin-list mailing list