]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.sbin/pstat/pstat.8
This commit was generated by cvs2svn to compensate for changes in r107606,
[FreeBSD/FreeBSD.git] / usr.sbin / pstat / pstat.8
1 .\" Copyright (c) 1980, 1991, 1993, 1994
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\" Copyright (c) 2002 Networks Associates Technology, Inc.
4 .\" All rights reserved.
5 .\"
6 .\" Portions of this software was developed for the FreeBSD Project by
7 .\" ThinkSec AS and NAI Labs, the Security Research Division of Network
8 .\" Associates, Inc.  under DARPA/SPAWAR contract N66001-01-C-8035
9 .\" ("CBOSS"), as part of the DARPA CHATS research program.
10 .\"
11 .\" Redistribution and use in source and binary forms, with or without
12 .\" modification, are permitted provided that the following conditions
13 .\" are met:
14 .\" 1. Redistributions of source code must retain the above copyright
15 .\"    notice, this list of conditions and the following disclaimer.
16 .\" 2. Redistributions in binary form must reproduce the above copyright
17 .\"    notice, this list of conditions and the following disclaimer in the
18 .\"    documentation and/or other materials provided with the distribution.
19 .\" 3. All advertising materials mentioning features or use of this software
20 .\"    must display the following acknowledgement:
21 .\"     This product includes software developed by the University of
22 .\"     California, Berkeley and its contributors.
23 .\" 4. Neither the name of the University nor the names of its contributors
24 .\"    may be used to endorse or promote products derived from this software
25 .\"    without specific prior written permission.
26 .\"
27 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
28 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
29 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
31 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
36 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37 .\" SUCH DAMAGE.
38 .\"
39 .\"     @(#)pstat.8     8.5 (Berkeley) 5/13/94
40 .\" $FreeBSD$
41 .\"
42 .Dd May 23, 2002
43 .Dt PSTAT 8
44 .Os
45 .Sh NAME
46 .Nm pstat ,
47 .Nm swapinfo
48 .Nd display system data structures
49 .Sh SYNOPSIS
50 .Nm
51 .Op Fl Tfknst
52 .Op Fl M Ar core
53 .Op Fl N Ar system
54 .Pp
55 .Nm swapinfo
56 .Op Fl k
57 .Op Fl M Ar core
58 .Op Fl N Ar system
59 .Sh DESCRIPTION
60 The
61 .Nm
62 utility displays open file entry, swap space utilization,
63 terminal state, and vnode data structures.
64 .Pp
65 If invoked as
66 .Nm swapinfo
67 the
68 .Fl s
69 option is implied, and only the
70 .Fl k
71 option is legal.
72 .Pp
73 The following options are available:
74 .Bl -tag -width indent
75 .It Fl n
76 Print devices out by major/minor instead of name.
77 .It Fl k
78 Print sizes in kilobytes, regardless of the setting of the
79 .Ev BLOCKSIZE
80 environment variable.
81 .It Fl T
82 Print the number of used and free slots in several system tables.
83 This is useful for checking to see how large system tables have become
84 if the system is under heavy load.
85 .It Fl f
86 Print the open file table with these headings:
87 .Bl -tag -width indent
88 .It LOC
89 The core location of this table entry.
90 .It TYPE
91 The type of object the file table entry points to.
92 .It FLG
93 Miscellaneous state variables encoded thus:
94 .Pp
95 .Bl -tag -width indent -compact
96 .It R
97 open for reading
98 .It W
99 open for writing
100 .It A
101 open for appending
102 .It I
103 signal pgrp when data ready
104 .El
105 .It CNT
106 Number of processes that know this open file.
107 .It MSG
108 Number of messages outstanding for this file.
109 .It DATA
110 The location of the vnode table entry or socket structure for this file.
111 .It OFFSET
112 The file offset (see
113 .Xr lseek 2 ) .
114 .El
115 .It Fl s
116 Print information about swap space usage on all the
117 swap areas compiled into the kernel.
118 The first column is the device name of the partition.  The next column is
119 the total space available in the partition.  The
120 .Ar Used
121 column indicates the total blocks used so far;  the
122 .Ar Available
123 column indicates how much space is remaining on each partition.
124 The
125 .Ar Capacity
126 reports the percentage of space used.
127 .Pp
128 If more than one partition is configured into the system, totals for all
129 of the statistics will be reported in the final line of the report.
130 .Pp
131 If you supply the option again, as in
132 .Fl ss ,
133 the system will display a breakdown of the swap bitmap/radix-tree.
134 .It Fl t
135 Print table for terminals
136 with these headings:
137 .Bl -tag -width indent
138 .It RAW
139 Number of characters in raw input queue.
140 .It CAN
141 Number of characters in canonicalized input queue.
142 .It OUT
143 Number of characters in output queue.
144 .It MODE
145 See
146 .Xr tty 4 .
147 .It ADDR
148 Physical device address.
149 .It DEL
150 Number of delimiters (newlines) in canonicalized input queue.
151 .It COL
152 Calculated column position of terminal.
153 .It STATE
154 Miscellaneous state variables encoded thus:
155 .Pp
156 .Bl -tag -width indent -compact
157 .It T
158 delay timeout in progress
159 .It W
160 waiting for open to complete
161 .It O
162 open
163 .It F
164 outq has been flushed during DMA
165 .It C
166 carrier is on
167 .It c
168 connection open
169 .It B
170 busy doing output
171 .It A
172 process is waiting for space in output queue
173 .It a
174 process is waiting for output to complete
175 .It X
176 open for exclusive use
177 .It S
178 output stopped (ixon flow control)
179 .It m
180 output stopped (carrier flow control)
181 .It o
182 output stopped (CTS flow control)
183 .It d
184 output stopped (DSR flow control)
185 .It K
186 input stopped
187 .It Y
188 send SIGIO for input events
189 .It D
190 state for lowercase
191 .Ql \e
192 work
193 .It E
194 within a
195 .Ql \e.../
196 for PRTRUB
197 .It L
198 next character is literal
199 .It P
200 retyping suspended input (PENDIN)
201 .It N
202 counting tab width, ignore FLUSHO
203 .It l
204 block mode input routine in use
205 .It s
206 i/o being snooped
207 .It Z
208 connection lost
209 .El
210 .It SESS
211 Kernel address of the session structure.
212 .It PGID
213 Process group for which this is controlling terminal.
214 .It DISC
215 Line discipline;
216 .Ql term
217 for
218 TTYDISC
219 or
220 .Ql ntty
221 for
222 NTTYDISC
223 or
224 .Ql tab
225 for
226 TABLDISC
227 or
228 .Ql slip
229 for
230 SLIPDISC
231 or
232 .Ql ppp
233 for
234 PPPDISC.
235 .El
236 .It Fl M
237 Extract values associated with the name list from the specified core
238 instead of the default
239 .Pa /dev/kmem .
240 .It Fl N
241 Extract the name list from the specified system instead of the default
242 .Pa /boot/kernel/kernel .
243 .El
244 .Sh FILES
245 .Bl -tag -width /boot/kernel/kernel -compact
246 .It Pa /boot/kernel/kernel
247 namelist
248 .It Pa /dev/mem
249 default source of tables
250 .El
251 .Sh SEE ALSO
252 .Xr ps 1 ,
253 .Xr systat 1 ,
254 .Xr stat 2 ,
255 .Xr fs 5 ,
256 .Xr iostat 8 ,
257 .Xr vmstat 8
258 .Rs
259 .%T UNIX Implementation
260 .%A K. Thompson
261 .Re
262 .Sh BUGS
263 Does not understand
264 .Tn NFS
265 swap servers.
266 .Sh HISTORY
267 The
268 .Nm
269 utility appeared in
270 .Bx 4.0 .