1MPSTAT(1)                     Linux User's Manual                    MPSTAT(1)
2
3
4

NAME

6       mpstat - Report processors related statistics.
7

SYNOPSIS

9       mpstat [ -A ] [ -I { SUM | CPU | ALL } ] [ -u ] [ -P { cpu [,...] | ALL
10       } ] [ -V ] [ interval [ count ] ]
11

DESCRIPTION

13       The mpstat command writes to standard output activities for each avail‐
14       able processor, processor 0 being the first one.  Global average activ‐
15       ities among all processors are also reported.  The mpstat  command  can
16       be  used  both  on  SMP and UP machines, but in the latter, only global
17       average activities will be printed. If no activity has  been  selected,
18       then the default report is the CPU utilization report.
19
20       The  interval parameter specifies the amount of time in seconds between
21       each report.  A value of 0 (or no parameters  at  all)  indicates  that
22       processors  statistics  are  to  be  reported for the time since system
23       startup (boot).  The count parameter can be  specified  in  conjunction
24       with  the  interval parameter if this one is not set to zero. The value
25       of count determines the number of reports generated at interval seconds
26       apart. If the interval parameter is specified without the count parame‐
27       ter, the mpstat command generates reports continuously.
28
29

OPTIONS

31       -A     This option is equivalent to specifying -I ALL -u -P ALL
32
33       -I { SUM | CPU | ALL }
34              Report interrupts statistics.
35
36              With the SUM keyword, the mpstat command reports the total  num‐
37              ber  of interrupts per processor.  The following values are dis‐
38              played:
39
40              CPU
41                     Processor number. The keyword all indicates that  statis‐
42                     tics are calculated as averages among all processors.
43
44              intr/s
45                     Show  the  total number of interrupts received per second
46                     by the CPU or CPUs.
47
48              With the CPU keyword, the number of  each  individual  interrupt
49              received per second by the CPU or CPUs is displayed.
50
51              The  ALL  keyword  is  equivalent to specifying all the keywords
52              above and therefore all the interrupts statistics are displayed.
53
54       -P { cpu [,...] | ALL }
55              Indicate the processor number for which  statistics  are  to  be
56              reported.  cpu is the processor number. Note that processor 0 is
57              the first processor.  The ALL keyword indicates that  statistics
58              are to be reported for all processors.
59
60       -u     Report CPU utilization. The following values are displayed:
61
62              CPU
63                     Processor  number. The keyword all indicates that statis‐
64                     tics are calculated as averages among all processors.
65
66              %usr
67                     Show the percentage  of  CPU  utilization  that  occurred
68                     while executing at the user level (application).
69
70              %nice
71                     Show  the  percentage  of  CPU  utilization that occurred
72                     while executing at the user level with nice priority.
73
74              %sys
75                     Show the percentage  of  CPU  utilization  that  occurred
76                     while  executing  at the system level (kernel). Note that
77                     this does not include time spent servicing  hardware  and
78                     software interrupts.
79
80              %iowait
81                     Show  the  percentage  of  time that the CPU or CPUs were
82                     idle during which the system had an outstanding disk  I/O
83                     request.
84
85              %irq
86                     Show  the  percentage of time spent by the CPU or CPUs to
87                     service hardware interrupts.
88
89              %soft
90                     Show the percentage of time spent by the CPU or  CPUs  to
91                     service software interrupts.
92
93              %steal
94                     Show  the percentage of time spent in involuntary wait by
95                     the virtual CPU or CPUs while the hypervisor was  servic‐
96                     ing another virtual processor.
97
98              %guest
99                     Show  the  percentage of time spent by the CPU or CPUs to
100                     run a virtual processor.
101
102              %idle
103                     Show the percentage of time that the  CPU  or  CPUs  were
104                     idle  and the system did not have an outstanding disk I/O
105                     request.
106
107              Note: On SMP machines a processor that does not have any  activ‐
108              ity at all is a disabled (offline) processor.
109
110       -V     Print version number then exit.
111
112

ENVIRONMENT

114       The  mpstat  command takes into account the following environment vari‐
115       able:
116
117
118       S_TIME_FORMAT
119              If this variable exists and its value is ISO  then  the  current
120              locale  will  be  ignored  when  printing the date in the report
121              header.  The mpstat command will use the ISO 8601 format  (YYYY-
122              MM-DD) instead.
123
124

EXAMPLES

126       mpstat 2 5
127              Display  five  reports of global statistics among all processors
128              at two second intervals.
129
130       mpstat -P ALL 2 5
131              Display five reports of statistics for  all  processors  at  two
132              second intervals.
133
134

BUGS

136       /proc filesystem must be mounted for the mpstat command to work.
137
138       Only a few activities are given by the Linux kernel for each processor.
139
140

FILES

142       /proc contains various files with system statistics.
143
144

AUTHOR

146       Sebastien Godard (sysstat <at> orange.fr)
147

SEE ALSO

149       sar(1), pidstat(1), iostat(1), vmstat(8)
150
151       http://pagesperso-orange.fr/sebastien.godard/
152
153
154
155Linux                              MAY 2009                          MPSTAT(1)
Impressum