Categories: Development

Understanding CPU server load

Server CPU load is the amount of CPU tasks waiting to be processed and running, The outcome is relative to the amount of CPU available. A load of 1 when you have 2 cores means you are using 50% of the CPU allowance at that time.

Once you get to 100% tasks have to wait like a  queue to get processed.

In Linux systems you can view server load a few ways:

cat /proc/loadavg
uptime
htop
top

Server CPU load will look like this:

For the last minute 0.40 processes have been waiting,  Past 5 minutes it has been 0.58 and over the past 15 minutes an average of 0.56 processes have had to wait.

Running nproc tells me I have 8 CPU processing units available on this system.

That means for me to have max CPU use (100%) I would need to see Load average: 8…

As a good rule of thumb if the nproc number is above your load number you likely have high server CPU load. If the load is under half of your nproc output or even better under 1 you are running the server under its capacity.

If you had a 1 vCPU virtual container that had Load Average 1.1 0.92 0.86 you are using close to, at and even over 100%

Share

Recent Posts

Kennington reservoir drained drone images

A drained and empty Kennington reservoir images from a drone in early July 2024. The…

2 years ago

Merrimu Reservoir drone images

Merrimu Reservoir from drone. Click images to view larger.

2 years ago

Early September spring shots

Some early September spring shots from a bushwalk, It is still too early for wildflowers.

3 years ago

Cloning an NVMe to SK Hynix Platinum P41 NVMe

I recently needed to clone over a smaller NVMe to a 2TB SK Hynix Platinum…

3 years ago

Using Laravel’s deleteDirectory to delete folders and their contents

If you ever needed a simple solution in Laravel to delete an entire directory and…

3 years ago

How to allow only 1 user to register in a Laravel application

How to enforce only one user to register or be registered in a Laravel web…

3 years ago