In one of our production Linux servers, CPU utilization is crossing 100 % and sometimes it is 250%.
How can I find which process is using more CPU utilization and where can I find CPU utilization logs?
OS : RHEL 5.5
feedback
|
This question came from our site for professional and enthusiast programmers.
|
CPU utilization is measured relative to a single CPU. The maximum is 100% for each CPU, so a four-CPU system would have a maximum CPU utilization of 400%. | |||
|
feedback
|
|
The A far better option is to install a monitoring system such as Cacti, Munin or Zabbix. (Although Nagios can do graphing, this is not its forte.) There are plenty of questions on ServerFault already about which monitoring system is the best. Once you install one of them, you will have trouble remembering how you lived without it. Generally, these will not tell you which process was using all the CPU at any given time. For that, The other key metric to watch is the "load average". This is an indication of how many processes are currently waiting to get on a processor. This is a very good indicator of how slow your system will feel to use. Another note on CPU utilisation, virtual machines can dynamically alter the CPU capacity in response to the needs of the VM. I have seen a single process showing up as using 9999% CPU in top from within a VM. The advice given by VMWare about this is "Don't trust metrics measured from within the VM". | |||
|
feedback
|
|
Another option is to use the
| |||
|
feedback
|
|
There is no logging of process utilization, you might want to install something like | |||
|
feedback
|
|
Not sure what you use to measure the utilization but you can use:
| |||
|
feedback
|
|
Others have mentioned top. If you want, you can run | |||
|
feedback
|
|
I have answered a similar question to this. You may want to enhance that script for your own needs. Basically, the command | |||
|
feedback
|
|
Don't forget top will run almost anywhere on an unrooted android phone. | |||||
feedback
|