7 using the prstat command, 1 options, Using the prstat – FUJITSU SPARC ENTERPRISE M5000 User Manual

Page 74: Options

Advertising
background image

2-36

SPARC Enterprise M4000/M5000 Servers Service Manual • August 2009

2.7.7

Using the prstat Command

The prstat utility iteratively examines all active processes and reports statistics
based on the selected output mode and sort order. The prstat command provides
output similar to the ps command.

2.7.7.1

Options

TABLE 2-18

describes options for the prstat command and how those options can

help troubleshooting.

The following example shows output for the prstat command.

TABLE 2-18

Options for

prstat

Option

Description

How It Can Help

No option

Displays a sorted list of the top
processes that are consuming
the most CPU resources. List is
limited to the height of the
terminal window and the total
number of processes. Output is
automatically updated every
five seconds. Ctrl-C aborts.

Output identifies process ID, user ID, memory used, state,
CPU consumption, and command name.

-n

number

Limits output to number of
lines.

Limits amount of data displayed and identifies primary
resource consumers.

-s

key

Permits sorting list by key
parameter.

Useful keys are

cpu

(default),

time

, and

size

.

-v

Verbose mode.

Displays additional parameters.

# prstat -n 5 -s size

PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP

100463 root 66M 61M sleep 59 0 0:01:03 0.0% fmd/19

100006 root 11M 9392K sleep 59 0 0:00:09 0.0% svc.configd/16

100004 root 10M 8832K sleep 59 0 0:00:04 0.0% svc.startd/14

100061 root 9440K 6624K sleep 59 0 0:00:01 0.0% snmpd/1

100132 root 8616K 5368K sleep 59 0 0:00:04 0.0% nscd/35

Total: 52 processes, 188 lwps, load averages: 0.00, 0.00, 0.00

#

Advertising