Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm testing some software on a particular four core machine. Is there an option for top or a similar utility that can tell how much each core is being used for a particular job?

share|improve this question
up vote 2 down vote accepted

Try

 mpstat -P ALL

mpstat is part of the the sysstat package.

Output look like this -

07:44:18     CPU   %user   %nice %system %iowait    %irq   %soft   %idle    intr/s
07:44:18     all    3.01   57.31    0.36    0.13    0.01    0.00   39.19   1063.46
07:44:18       0    5.87   69.47    0.44    0.05    0.01    0.01   24.16    262.11
07:44:18       1    1.79   48.59    0.36    0.23    0.00    0.00   49.02    268.92
07:44:18       2    2.19   42.63    0.28    0.16    0.01    0.00   54.73    260.96
07:44:18       3    2.17   68.56    0.34    0.06    0.03    0.00   28.83    271.47

This page will be helpful for you - http://www.cyberciti.biz/tips/how-do-i-find-out-linux-cpu-utilization.html

share|improve this answer

htop. Configurable, detailed, and a little more user friendly than standard top.

share|improve this answer
    
Does it actually show per core usage? – Daniel Beck Sep 14 '11 at 20:58
    
@Daniel It has an option, under the "Columns" tab under "Setup", which is named "PROCESSOR". This will tell you which processor a process/thread is resident on, and the seperate "PERCENT_CPU" column will tell you how much CPU% it is using. So, yes. Kind of. – new123456 Sep 14 '11 at 23:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .