.\" Copyright (c) 1980, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
.\" @(#)pstat.8 8.1 (Berkeley) 6/6/93
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\" 3. All advertising materials mentioning features or use of this software
.\" must display the following acknowledgement:
.\" This product includes software developed by the University of
.\" California, Berkeley and its contributors.
.\" 4. Neither the name of the University nor the names of its contributors
.\" may be used to endorse or promote products derived from this software
.\" without specific prior written permission.
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" @(#)pstat.8 8.1 (Berkeley) 6/6/93
.Nd display system data structures
displays open file entry, swap space utilization,
terminal state, and vnode data structures.
is given, the information is sought there, otherwise
The required namelist is taken from
option specifies that devices should be printed out by major/minor
number rather than by name.
Prints the number of used and free slots in the several system tables
and is useful for checking to see how large system tables have become
if the system is under heavy load.
Print the open file table with these headings:
The core location of this table entry.
The type of object the file table entry points to.
Miscellaneous state variables encoded thus:
signal pgrp when data ready
Number of processes that know this open file.
Number of messages outstanding for this file.
The location of the vnode table entry or socket structure for this file.
Print information about swap space usage on all the
swap areas compiled into the kernel.
The first column is the device name of the partition. The next column is
the total space available in the partition. The
column indicates the total blocks used so far; the
column indicates how much space is remaining on each partition.
reports the percentage of space used.
If more than one partition is configured into the system, totals for all
of the statistics will be reported in the final line of the report.
Print table for terminals
Number of characters in raw input queue.
Number of characters in canonicalized input queue.
Number of characters in putput queue.
Number of delimiters (newlines) in canonicalized input queue.
Calculated column position of terminal.
Miscellaneous state variables encoded thus:
delay timeout in progress
waiting for open to complete
outq has been flushed during DMA
process is awaiting output
Process group for which this is controlling terminal.
Line discipline; blank is old tty
Print the active vnodes. Each group of vnodes coresponding
to a particular filesystem is preceded by a two line header. The
first line consists of the following:
.No *** MOUNT Em fstype from
.Em ufs , nfs , mfs , or pc ;
is the filesystem is mounted from;
the filesystem is mounted on; and
of optional flags applied to the mount (see
.The second line is a header for the individual fields ,
the first part of which are fixed, and the second part are filesystem
type specific. The headers common to all vnodes are:
A list of letters representing vnode flags:
The core location of this table entry.
Miscellaneous state variables encoded thus:
access time must be corrected
wanted by another process (L flag is on)
changed time must be corrected
someone waiting for a lock
Number of open file table entries for this inode.
Major and minor device number of file system in which
Reference count of shared locks on the inode.
Reference count of exclusive locks on the inode (this may
be > 1 if, for example, a file descriptor is inherited across a fork).
I-number within the device.
Number of links to this inode.
Number of bytes in an ordinary file, or
major and minor device of special file.
.Bl -tag -width /dev/kmemxxx -compact
.Rt Tn UNIX Rt Implementation ,
Swap statistics are reported for all swap partitions compiled into the kernel,
regardless of whether those partitions are being used.
Does not understand NFS swap servers.
command appeared in 4.0BSD.