Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I thought the average load by uptime and the summation of %CPU of all running processes in top (#9 column) should agree. But it seems not true. Here is my little experiments:

On one server:

$ top -b -n 1| awk '{ totuse = totuse + $9 } END { print totuse/100 }'; uptime


22:00:59 up 28 days,  7:03,  9 users,  load average: 7.03, 5.81, 4.51`

On another server:

$ top -b -n 1| awk '{ totuse = totuse + $9 } END { print totuse/100 }'; uptime


22:01:37 up 29 days,  8:27, 17 users,  load average: 18.83, 16.01, 13.86`

So why is there such a difference between the two? Which one more truly reflect the usage of CPUs?

If I try to evaluate how much CPU usage my running processes are using, is this a good way:

top -b -n 1 | grep "tim"| awk '{ totuse = totuse + $9 } END { print totuse/100 }'


Thanks and regards!

share|improve this question
up vote 8 down vote accepted

The reason your CPU % and load average are not agreeing is because they are two completely different values. The CPU % is exactly that, the percentage of the CPU a process is using. The load average is the weighted average of the processes in the run queue over 1, 5, and 15 minutes.

If you are concerned with how much CPU you are using (are you fully utilizing your CPU), your tally of the output of top will work well. You can run that occasionally and record the value (or use sar, which will do that for you).

Having a high load average means you have a lot of processes in the run queue - many processes are ready and waiting to run. High load doesn't automatically mean a lot of CPU usage.

Wikipedia has a good article describing the load average, and the differences between CPU load and CPU usage:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.