CPU idle

hi
when should we consider that CPU is loaded? When it is 100% idle or 0%idle??

tx

cpu is 0% idle, that means it is heavy loaded... 100% idle means it is doing nothing...

regards pressy

cpu is 0% idle, that means it is heavy loaded. so that could be due to processes consuming all cpu. right?

100% idle means it is doing nothing...> so that can be a dealock or a process hanging. right?

both of them (0 and 100%) are not a good sign. right?

Right. That's not necessarily bad, though. A system running at 100% CPU can still be quite responsive since CPU time is split relatively fairly among competing processes according to their priority levels. Two competing processes at the same priority level will split time 50/50... Or if they have different priority levels(see 'man nice' and 'man renice') the higher-priority process will get the majority of the time.

More likely the system just plain has nothing to do. Or you weren't looking at the right instant. Remember that most programs either start and finish in an instant, or sleep 99% of the time waiting for some sort of trigger. Unless the monitor updates at the exact right instant, you won't notice either.

Both of them are neither good nor bad in themselves. 100% CPU could just be somebody compressing a big file. 0% CPU could just mean the system has nothing to process at that particular instant.

0% is very unsual, low single digits on an idle machine is not.

continuous 100% is bad, you may get a process grabbing everything that is available, but as Corona said, unless a process or thread it is scheduled with a higher than normal prority or is non-preemptable this should not cause the system major problems, it will just have to share with everyone else. An example of this would be something like running a large build which will probably grab every idle cycle you have.

If a server it "normally" using 100% of CPU it means that it is under spec for the workload ( any of memory or cpu or IO depending on the workload ) OR has one or more runnaway process that are hogging cpu.