Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mac OS X shell utility that shows individual cpu usage in multi-core systems

I've been looking for a osx utility that shows cpu usage for each cpu. For example CPU 0 - 10% CPU 1 - 2% ...

I know of many ways of getting this information in other Unix-like system (/proc, mpstat, etc) but none work in osx. The most useful one for Mac is top but it only shows total cpu usage. I need the application to be run from the shell so that I can log the usage over time. I also tried cpuwalk.d but it only shows you if the application is running in one or more cores.

If you take a look at Activity Monitor app you will notice that it basically displays the same info as top, but with the addition of a graph that shows cpus load.

If anyone has any idea of how to get the information I would appreciate it. Thanks.

like image 728
F2_CMD Avatar asked Mar 16 '12 20:03

F2_CMD


People also ask

How do I stress test my CPU Mac?

How to run a CPU performance test. Your Mac's Activity Monitor will show you how much CPU capacity is being used by macOS and any apps you have open. To launch Activity Monitor, select the Applications folder in your Finder window, double-click Utilities, and select Activity Monitor.

What is Kernel_task Mac?

The kernel_task process is at the core of macOS, and it includes a variety of low-level functions that allow the computer to work. One of its primary functions is ensuring your Mac doesn't overheat.

How do I view Activity Monitor on Mac?

To find Activity Monitor on a Mac, go to your Applications folder > Utilities folder, and then double-click Activity Monitor. There you'll see a simple app with five tabs, and a list of entries that changes every few seconds.


1 Answers

You can try htop. If you have homebrew installed, simple install it via "brew install htop", after the installation finished, type in htop on the shell.

like image 61
Tyrael Tong Avatar answered Oct 03 '22 02:10

Tyrael Tong