GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
PCPUSTAT(1) FreeBSD General Commands Manual PCPUSTAT(1)

pcpustat
per-CPU usage statistics

pcpustat [-ahinqstux] [-c count] [-d delimiter] [-p cpu] [-w wait]

The pcpustat utility provides per-CPU usage statistics. This information is computed using the same algorithm as in top(1) with the -P option, but the output format is more similar to that of iostat(8) so that it can be piped and reformatted.

-all
Include all usage statistics (same as -instu). This is the default if no specific statistics are selected.
-count count
Sample statistics the specified number of times. If not specified, it defaults to 1 if -w is not specified, otherwise forever.
-delim delimiter
Delimit columns with delimiter instead of justifying them with spaces.
-help
Print the list of options and exit.
-idle
Include idle time in the statistics.
-nice
Include nice time in the statistics.
-cpu cpu
Select processor cpu [0-n]. You may repeat the switch to select more than one CPU. The default is to include all CPUs.
-quiet
Print no header, only the data.
-system
Include system time in the statistics.
-interrupt
Include interrupt time in the statistics.
-user
Include user time in the statistics.
-wait wait
Pause the specified number of seconds between updates. The default is 1.
-not
Report the percentage of time not in each state. If specified, each percentage is subtracted from 100. The header (unless the -q option is selected) displays a "!" before each heading.

If the [-q] option is not specified, the first two lines of output will contain a header.

The first line lists the CPUs, by number. If the options specify only one column of information per CPU, then this line will only contain the CPU numbers (starting with 0), otherwise it will contain the string "cpu " followed by the number. This heading will be right-justified over the columns that apply to that CPU, unless the [-d] option is specified (in which case the headers are also delimited).

The second header line labels the columns within the output for each CPU. These labels can be any of the following:

us
% of cpu time in user mode
ni
% of cpu time in user mode running niced processes
sy
% of cpu time in system mode
in
% of cpu time in interrupt mode
id
% of cpu time in idle mode

If the [-x] option was specified, then each of the above is prefixed by '!'.

The remaining lines of output will be the percentage of time each CPU spent in each of the designated states since the previous line (or since pcpustat started, in the case of the first line).

If the [-d] option is specified, then the string specified as its argument will occur between each column. Otherwise, enough spaces will be used to right-align each column under its heading.

top(1), iostat(8), sysctl(3), sysctl(8)

Sterling (Chip) Camden <sterling@camdensoftware.com>

http://chipstips.com/?tag=c_pcpustat

The pcpustat utility can only report on CPUs 0-n, where n is one less than the number of bits in a long.
September 26, 2010 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.