xref: /openbsd-src/usr.sbin/iostat/iostat.8 (revision 2b0358df1d88d06ef4139321dd05bd5e05d91eaf)
1.\"	$OpenBSD: iostat.8,v 1.23 2007/05/31 19:20:25 jmc Exp $
2.\"	$NetBSD: iostat.8,v 1.10 1996/10/25 18:21:57 scottr Exp $
3.\"
4.\" Copyright (c) 1985, 1991, 1993
5.\"	The Regents of the University of California.  All rights reserved.
6.\"
7.\" Redistribution and use in source and binary forms, with or without
8.\" modification, are permitted provided that the following conditions
9.\" are met:
10.\" 1. Redistributions of source code must retain the above copyright
11.\"    notice, this list of conditions and the following disclaimer.
12.\" 2. Redistributions in binary form must reproduce the above copyright
13.\"    notice, this list of conditions and the following disclaimer in the
14.\"    documentation and/or other materials provided with the distribution.
15.\" 3. Neither the name of the University nor the names of its contributors
16.\"    may be used to endorse or promote products derived from this software
17.\"    without specific prior written permission.
18.\"
19.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
20.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
23.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29.\" SUCH DAMAGE.
30.\"
31.\"	from: @(#)iostat.8	8.1 (Berkeley) 6/6/93
32.\"
33.Dd $Mdocdate: May 31 2007 $
34.Dt IOSTAT 8
35.Os
36.Sh NAME
37.Nm iostat
38.Nd report I/O statistics
39.Sh SYNOPSIS
40.Nm iostat
41.Op Fl CDdIT
42.Op Fl c Ar count
43.Op Fl M Ar core
44.Op Fl N Ar system
45.Op Fl w Ar wait
46.Op Ar drives
47.Sh DESCRIPTION
48.Nm
49displays kernel I/O statistics on terminal, disk and CPU operations.
50By default,
51.Nm
52displays one line of statistics averaged over the machine's run time.
53The use of
54.Fl c
55presents successive lines averaged over the
56.Ar wait
57period.
58The
59.Fl I
60option causes
61.Nm iostat
62to print raw, unaveraged values.
63.Pp
64The options are as follows:
65.Bl -tag -width Ds
66.It Fl C
67Show CPU statistics.
68This is enabled by default unless the
69.Fl D ,
70.Fl d ,
71or
72.Fl T
73flags are used.
74.It Fl c Ar count
75Repeat the display
76.Ar count
77times.
78Unless the
79.Fl I
80flag is in effect, the first display is for the time since a reboot and
81each subsequent report is for the time period since the last display.
82If no
83.Ar wait
84interval is specified, the default is 1 second.
85.It Fl D
86Show alternate disk statistics.
87Displays kilobytes transferred, number of
88transfers, and time spent in transfers.
89Use of this flag disables the default display.
90.It Fl d
91Show disk statistics.
92This is the default.
93Displays kilobytes per
94transfer, number of transfers, and megabytes transferred.
95Use of this flag disables display of CPU and tty statistics.
96.It Fl I
97Show the running total values, rather than an average.
98.It Fl M Ar core
99Extract values associated with the name list from the specified
100.Ar core
101instead of the default
102.Pa /dev/mem .
103.It Fl N Ar system
104Extract the name list from the specified
105.Ar system
106instead of the default
107.Dq Pa /bsd .
108.It Fl T
109Show tty statistics.
110This is enabled by default unless the
111.Fl C ,
112.Fl D ,
113or
114.Fl d
115flags are used.
116.It Fl w Ar wait
117Pause
118.Ar wait
119seconds between each display.
120If no repeat
121.Ar count
122is specified, the default is infinity.
123.El
124.Pp
125.Nm
126displays its information in the following format:
127.Bl -tag -width flag
128.It tty
129.Bl -tag -width indent -compact
130.It tin
131characters read from terminals
132.It tout
133characters written to terminals
134.El
135.It disks
136Disk operations.
137The header of the field is the disk name and unit number.
138If more than four disk drives are configured in the system,
139.Nm
140displays only the first four drives.
141To force
142.Nm
143to display specific drives, their names may be supplied on the command
144line.
145.Pp
146.Bl -tag -width indent -compact
147.It KB/t
148Kilobytes transferred per disk transfer
149.It t/s
150Transfers per second
151.It MB/s
152Megabytes transferred per second
153.Pp
154.El
155The alternate display format, (selected with
156.Fl D ) ,
157presents the following values:
158.Pp
159.Bl -tag -width indent -compact
160.It KB
161Kilobytes transferred
162.It xfr
163Disk transfers
164.It time
165Seconds spent in disk activity
166.El
167.It cpu
168.Bl -tag -width indent -compact
169.It \&us
170% of CPU time in user mode
171.It \&ni
172% of CPU time in user mode running niced processes
173.It \&sy
174% of CPU time in system mode
175.It \&in
176% of CPU time processing interrupts
177.It \&id
178% of CPU time in idle mode
179.El
180.El
181.Sh FILES
182.Bl -tag -width /dev/mem -compact
183.It Pa /bsd
184default kernel namelist
185.It Pa /dev/mem
186default memory file
187.El
188.Sh SEE ALSO
189.Xr fstat 1 ,
190.Xr netstat 1 ,
191.Xr nfsstat 1 ,
192.Xr ps 1 ,
193.Xr systat 1 ,
194.Xr top 1 ,
195.Xr pstat 8 ,
196.Xr vmstat 8
197.Pp
198The sections starting with
199.Dq Interpreting system activity
200in
201.%T "Installing and Operating 4.3BSD" .
202