Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Understanding load average vs. cpu usage [closed]

Okay, I'm very much a Windows user myself, so my knowledge of Linux-y type things is a bit limited.

However it was my general understanding that "Load Average" is an indication of how many processed are being run at any given time, on average over the last minute, five minutes and... fifteen minutes?

Anyway, I've been monitoring my server because we had a big opening and lots of people!

See?

I've been watching top and noticed something that seemed contrary to what I thought I knew.

If the load average is at 7, with 4 hyper-threaded processors, shouldn't that means that the CPU is working to about 7/8 capacity?

Why, then was it showing 50.0%id? How can it be idle half the time?

like image 696
Niet the Dark Absol Avatar asked Feb 07 '14 01:02

Niet the Dark Absol


People also ask

What is the difference between load average and CPU utilization?

System load/CPU Load – is a measurement of CPU over or under-utilization in a Linux system; the number of processes which are being executed by the CPU or in waiting state. Load average – is the average system load calculated over a given period of time of 1, 5 and 15 minutes.

How do you interpret CPU load average?

CPU load is the number of processes which are being executed by CPU or waiting to be executed by CPU. So CPU load average is the average number of processes being or waiting executed over past 1, 5 and 15 minutes. So the number shown above means: load average over the last 1 minute is 3.84.

What is a good CPU load average?

So, your CPU load should ideally stay below 1.00. Also, like the bridge operator, you are still ok if you get some temporary spikes above 1.00 ... but when you're consistently above 1.00, you need to worry.

What load average is too high?

As long as your server and applications are performing as expected, you don't need to worry too much about it. The load average values should be within 75% of the number of CPUs. If a server has 4 CPUs, then 75% of 4 is 3. The load average values should not exceed 3 in that case.


1 Answers

top shows CPU utilization for running processes while load average shows (since 1993) number of running processes plus number of processes in the uninterruptible state. Processes waiting for work do not consume CPU. As a result top CPU utilization is less that 7/8 * 100%.

Source: http://www.brendangregg.com/blog/2017-08-08/linux-load-averages.html

like image 68
6 revs, 2 users 100%user184968 Avatar answered Sep 22 '22 08:09

6 revs, 2 users 100%user184968