summaryrefslogtreecommitdiffstats
path: root/man/man5/proc_stat.5
blob: 3fe4c6fea9a33513be292bcdd5a72b11b41c8ca6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
.\" Copyright (C) 1994, 1995, Daniel Quinlan <quinlan@yggdrasil.com>
.\" Copyright (C) 2002-2008, 2017, Michael Kerrisk <mtk.manpages@gmail.com>
.\" Copyright (C) 2023, Alejandro Colomar <alx@kernel.org>
.\"
.\" SPDX-License-Identifier: GPL-3.0-or-later
.\"
.TH proc_stat 5 2024-05-02 "Linux man-pages (unreleased)"
.SH NAME
/proc/stat \- kernel system statistics
.SH DESCRIPTION
.TP
.I /proc/stat
kernel/system statistics.
Varies with architecture.
Common
entries include:
.RS
.TP
.I cpu  10132153 290696 3084719 46828483 16683 0 25195 0 175628 0
.TQ
.I cpu0 1393280 32966 572056 13343292 6130 0 17875 0 23933 0
The amount of time, measured in units of
USER_HZ (1/100ths of a second on most architectures, use
.I sysconf(_SC_CLK_TCK)
to obtain the right value),
.\" 1024 on Alpha and ia64
that the system ("cpu" line) or the specific CPU ("cpu\fIN\fR" line)
spent in various states:
.RS
.TP
.I user
(1) Time spent in user mode.
.TP
.I nice
(2) Time spent in user mode with low priority (nice).
.TP
.I system
(3) Time spent in system mode.
.TP
.I idle
(4) Time spent in the idle task.
.\" FIXME . Actually, the following info about the /proc/stat 'cpu' field
.\"       does not seem to be quite right (at least in Linux 2.6.12 or Linux 3.6):
.\"       the idle time in /proc/uptime does not quite match this value
This value should be USER_HZ times the
second entry in the
.I /proc/uptime
pseudo-file.
.TP
.IR iowait " (since Linux 2.5.41)"
(5) Time waiting for I/O to complete.
This value is not reliable, for the following reasons:
.\" See kernel commit 9c240d757658a3ae9968dd309e674c61f07c7f48
.RS
.IP \[bu] 3
The CPU will not wait for I/O to complete;
iowait is the time that a task is waiting for I/O to complete.
When a CPU goes into idle state for outstanding task I/O,
another task will be scheduled on this CPU.
.IP \[bu]
On a multi-core CPU,
the task waiting for I/O to complete is not running on any CPU,
so the iowait of each CPU is difficult to calculate.
.IP \[bu]
The value in this field may
.I decrease
in certain conditions.
.RE
.TP
.IR irq " (since Linux 2.6.0)"
.\" Precisely: Linux 2.6.0-test4
(6) Time servicing interrupts.
.TP
.IR softirq " (since Linux 2.6.0)"
.\" Precisely: Linux 2.6.0-test4
(7) Time servicing softirqs.
.TP
.IR steal " (since Linux 2.6.11)"
(8) Stolen time, which is the time spent in other operating systems when
running in a virtualized environment
.TP
.IR guest " (since Linux 2.6.24)"
(9) Time spent running a virtual CPU for guest
operating systems under the control of the Linux kernel.
.\" See Changelog entry for 5e84cfde51cf303d368fcb48f22059f37b3872de
.TP
.IR guest_nice " (since Linux 2.6.33)"
.\" commit ce0e7b28fb75cb003cfc8d0238613aaf1c55e797
(10) Time spent running a niced guest (virtual CPU for guest
operating systems under the control of the Linux kernel).
.RE
.TP
\fIpage 5741 1808\fP
The number of pages the system paged in and the number that were paged
out (from disk).
.TP
\fIswap 1 0\fP
The number of swap pages that have been brought in and out.
.TP
.\" FIXME . The following is not the full picture for the 'intr' of
.\"       /proc/stat on 2.6:
\fIintr 1462898\fP
This line shows counts of interrupts serviced since boot time,
for each of the possible system interrupts.
The first column is the total of all interrupts serviced
including unnumbered architecture specific interrupts;
each subsequent column is the total for that particular numbered interrupt.
Unnumbered interrupts are not shown, only summed into the total.
.TP
\fIdisk_io: (2,0):(31,30,5764,1,2) (3,0):\fP...
(major,disk_idx):(noinfo, read_io_ops, blks_read, write_io_ops, blks_written)
.br
(Linux 2.4 only)
.TP
\fIctxt 115315\fP
The number of context switches that the system underwent.
.TP
\fIbtime 769041601\fP
boot time, in seconds since the Epoch, 1970-01-01 00:00:00 +0000 (UTC).
.TP
\fIprocesses 86031\fP
Number of forks since boot.
.TP
\fIprocs_running 6\fP
Number of processes in runnable state.
(Linux 2.5.45 onward.)
.TP
\fIprocs_blocked 2\fP
Number of processes blocked waiting for I/O to complete.
(Linux 2.5.45 onward.)
.TP
.I softirq 229245889 94 60001584 13619 5175704 2471304 28 51212741 59130143 0 51240672
.\" commit d3d64df21d3d0de675a0d3ffa7c10514f3644b30
This line shows the number of softirq for all CPUs.
The first column is the total of all softirqs and
each subsequent column is the total for particular softirq.
(Linux 2.6.31 onward.)
.RE
.SH SEE ALSO
.BR proc (5)