CPU run queue length and load average are key metrics related to system performance. We will review what these two CPU metrics mean today.
- What is CPU RUN Queue Length on Linux
- What is Load Average
- How to Check High System Load Average
Table of Contents
What is CPU RUN Queue Length on Linux
In Linux, a process can be either runnable or blocked waiting for an event to complete. A blocked process may be waiting for data from an I/O device or the results of a system call. If a process is runnable, that means that it is competing for the CPU time with the other processes that are also runnable.
Get Your Free Linux training!
Join our free Linux training and discover the power of open-source technology. Enhance your skills and boost your career! Learn Linux for Free!A runnable process is not necessarily using the CPU, but when the Linux scheduler is deciding which process to run next, it picks from the list of runnable processes.
When these processes are runnable, but waiting to use the processor, they form a line called the run queue. The longer the run queue length, the more processes wait in line.
What is Load Average on Linux
The performance tools commonly show the number of processes that are runnable and the number of processes that are blocked waiting for I/O. Another common system statistic is that of load average.
The load on a system is the total amount of running and blocked process. For example, if two processes were running and five were blocked to run, the system’s load would be seven.
The load average is the amount of load over a given amount of time. Typically, the load average is taken over 1 minute, 5 minutes, and 15 minutes. This enables you to see how the load changes over time. Linux Performance: CPU Load Average
How to Check High System Load Average on Linux
Here is one cpu high load example on our production system. The load went to over 170. After checking, we found that many processes were blocked because of network loss to nfs storage. The system load average number is the same as the number of blocked processes. We fixed the issue after we reboot the server in the end.
Reference:
Optimizing Linux® Performance: A Hands-On Guide to Linux® Performance Tools
Related Post:
Linux Performance: CPU Load Average
CPU Utilization us sy wa hi means in Ubuntu Linux – Linux Performance