Print this page
2989 Eliminate use of LOGNAME_MAX in ON
1166 useradd have warning with name more 8 chars
   1 '\" te

   2 .\" Copyright (c) 2006, 2009 Sun Microsystems, Inc. All Rights Reserved.
   3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
   4 .\"  See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with
   5 .\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   6 .TH PRSTAT 1M "Jun 25, 2009"
   7 .SH NAME
   8 prstat \- report active process statistics
   9 .SH SYNOPSIS
  10 .LP
  11 .nf
  12 \fBprstat\fR [\fB-acHJLmRrtTv\fR] [\fB-d\fR u | d] [\fB-C\fR \fIpsrsetlist\fR] [\fB-h\fR \fIlgrplist\fR]
  13      [\fB-j\fR \fIprojlist\fR] [\fB-k\fR \fItasklist\fR] [\fB-n\fR \fIntop\fR[,\fInbottom\fR]]
  14      [\fB-p\fR \fIpidlist\fR] [\fB-P\fR \fIcpulist\fR] [\fB-s\fR \fIkey\fR | \fB-S\fR \fIkey\fR ]
  15      [\fB-u\fR \fIeuidlist\fR] [\fB-U\fR \fIuidlist\fR] [\fB-z\fR \fIzoneidlist\fR] [\fB-Z\fR]
  16      [\fIinterval\fR [\fIcount\fR]]
  17 .fi
  18 
  19 .SH DESCRIPTION
  20 .sp
  21 .LP
  22 The \fBprstat\fR utility iteratively examines all active processes on the
  23 system and reports statistics based on the selected output mode and sort order.
  24 \fBprstat\fR provides options to examine only processes matching specified
  25 \fBPID\fRs, \fBUID\fRs, zone \fBID\fRs, \fBCPU\fR \fBID\fRs, and processor set
  26 \fBID\fRs.
  27 .sp
  28 .LP
  29 The \fB-j\fR, \fB-k\fR, \fB-C\fR, \fB-p\fR, \fB-P\fR, \fB-u\fR, \fB-U\fR, and
  30 \fB-z\fR options accept lists as arguments. Items in a list can be either
  31 separated by commas or enclosed in quotes and separated by commas or spaces.
  32 .sp
  33 .LP
  34 If you do not specify an option, \fBprstat\fR examines all processes and
  35 reports statistics sorted by \fBCPU\fR usage.


  39 The following options are supported:
  40 .sp
  41 .ne 2
  42 .na
  43 \fB\fB-a\fR\fR
  44 .ad
  45 .sp .6
  46 .RS 4n
  47 Report information about processes and users. In this mode \fBprstat\fR
  48 displays separate reports about processes and users at the same time.
  49 .RE
  50 
  51 .sp
  52 .ne 2
  53 .na
  54 \fB\fB-c\fR\fR
  55 .ad
  56 .sp .6
  57 .RS 4n
  58 Print new reports below previous reports instead of overprinting them.

  59 .RE
  60 
  61 .sp
  62 .ne 2
  63 .na
  64 \fB\fB-C\fR \fIpsrsetlist\fR\fR
  65 .ad
  66 .sp .6
  67 .RS 4n
  68 Report only processes or lwps that are bound to processor sets in the given
  69 list. Each processor set is identified by an integer as reported by
  70 \fBpsrset\fR(1M). The load averages displayed are the sum of the load averages
  71 of the specified processor sets (see \fBpset_getloadavg\fR(3C)). Processes with
  72 one or more LWPs bound to processor sets in the given list are reported even
  73 when the \fB-L\fR option is not used.
  74 .RE
  75 
  76 .sp
  77 .ne 2
  78 .na


 111 .ne 2
 112 .na
 113 \fB\fB-j\fR \fIprojlist\fR\fR
 114 .ad
 115 .sp .6
 116 .RS 4n
 117 Report only processes or lwps whose project \fBID\fR is in the given list. Each
 118 project \fBID\fR can be specified as either a project name or a numerical
 119 project \fBID\fR. See \fBproject\fR(4).
 120 .RE
 121 
 122 .sp
 123 .ne 2
 124 .na
 125 \fB\fB-J\fR\fR
 126 .ad
 127 .sp .6
 128 .RS 4n
 129 Report information about processes and projects. In this mode \fBprstat\fR
 130 displays separate reports about processes and projects at the same time.


 131 .RE
 132 
 133 .sp
 134 .ne 2
 135 .na
 136 \fB\fB-k\fR \fItasklist\fR\fR
 137 .ad
 138 .sp .6
 139 .RS 4n
 140 Report only processes or lwps whose task \fBID\fR is in \fItasklist\fR.
 141 .RE
 142 
 143 .sp
 144 .ne 2
 145 .na
 146 \fB\fB-L\fR\fR
 147 .ad
 148 .sp .6
 149 .RS 4n
 150 Report statistics for each light-weight process (\fBLWP\fR). By default,


 347 \fBID\fR may be specified as either a login name or a numerical user \fBID\fR.
 348 .RE
 349 
 350 .sp
 351 .ne 2
 352 .na
 353 \fB\fB-v\fR\fR
 354 .ad
 355 .sp .6
 356 .RS 4n
 357 Report verbose process usage. This output format includes the percentage of
 358 time the process has spent in user mode, in system mode, and sleeping. It also
 359 includes the number of voluntary and involuntary context switches, system calls
 360 and the number of signals received. Statistics that are not reported are marked
 361 with the \fB-\fR sign.
 362 .RE
 363 
 364 .sp
 365 .ne 2
 366 .na













 367 \fB\fB-z\fR \fIzoneidlist\fR\fR
 368 .ad
 369 .sp .6
 370 .RS 4n
 371 Report only processes or LWPs whose zone ID is in the given list. Each zone ID
 372 can be specified as either a zone name or a numerical zone ID. See
 373 \fBzones\fR(5).
 374 .RE
 375 
 376 .sp
 377 .ne 2
 378 .na
 379 \fB\fB-Z\fR\fR
 380 .ad
 381 .sp .6
 382 .RS 4n
 383 Report information about processes and zones. In this mode, \fBprstat\fR
 384 displays separate reports about processes and zones at the same time.


 385 .RE
 386 
 387 .SH OUTPUT
 388 .sp
 389 .LP
 390 The following list defines the column headings and the meanings of a
 391 \fBprstat\fR report:
 392 .sp
 393 .ne 2
 394 .na
 395 \fBPID\fR
 396 .ad
 397 .sp .6
 398 .RS 4n
 399 The process \fBID\fR of the process.
 400 .RE
 401 
 402 .sp
 403 .ne 2
 404 .na
 405 \fBUSERNAME\fR
 406 .ad
 407 .sp .6
 408 .RS 4n
 409 The real user (login) name or real user \fBID\fR.


 410 .RE
 411 
 412 .sp
 413 .ne 2
 414 .na
 415 \fBSWAP\fR
 416 .ad
 417 .sp .6
 418 .RS 4n
 419 The total virtual memory size of the process, including all mapped files and
 420 devices, in kilobytes (\fBK\fR), megabytes (\fBM\fR), or gigabytes (\fBG\fR).
 421 .RE
 422 
 423 .sp
 424 .ne 2
 425 .na
 426 \fBRSS\fR
 427 .ad
 428 .sp .6
 429 .RS 4n


   1 '\" te
   2 .\" Copyright (c) 2013 Gary Mills
   3 .\" Copyright (c) 2006, 2009 Sun Microsystems, Inc. All Rights Reserved.
   4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
   5 .\"  See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with
   6 .\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   7 .TH PRSTAT 1M "Apr 15, 2013"
   8 .SH NAME
   9 prstat \- report active process statistics
  10 .SH SYNOPSIS
  11 .LP
  12 .nf
  13 \fBprstat\fR [\fB-acHJLmRrtTvWZ\fR] [\fB-d\fR u | d] [\fB-C\fR \fIpsrsetlist\fR] [\fB-h\fR \fIlgrplist\fR]
  14      [\fB-j\fR \fIprojlist\fR] [\fB-k\fR \fItasklist\fR] [\fB-n\fR \fIntop\fR[,\fInbottom\fR]]
  15      [\fB-p\fR \fIpidlist\fR] [\fB-P\fR \fIcpulist\fR] [\fB-s\fR \fIkey\fR | \fB-S\fR \fIkey\fR ]
  16      [\fB-u\fR \fIeuidlist\fR] [\fB-U\fR \fIuidlist\fR] [\fB-z\fR \fIzoneidlist\fR]
  17      [\fIinterval\fR [\fIcount\fR]]
  18 .fi
  19 
  20 .SH DESCRIPTION
  21 .sp
  22 .LP
  23 The \fBprstat\fR utility iteratively examines all active processes on the
  24 system and reports statistics based on the selected output mode and sort order.
  25 \fBprstat\fR provides options to examine only processes matching specified
  26 \fBPID\fRs, \fBUID\fRs, zone \fBID\fRs, \fBCPU\fR \fBID\fRs, and processor set
  27 \fBID\fRs.
  28 .sp
  29 .LP
  30 The \fB-j\fR, \fB-k\fR, \fB-C\fR, \fB-p\fR, \fB-P\fR, \fB-u\fR, \fB-U\fR, and
  31 \fB-z\fR options accept lists as arguments. Items in a list can be either
  32 separated by commas or enclosed in quotes and separated by commas or spaces.
  33 .sp
  34 .LP
  35 If you do not specify an option, \fBprstat\fR examines all processes and
  36 reports statistics sorted by \fBCPU\fR usage.


  40 The following options are supported:
  41 .sp
  42 .ne 2
  43 .na
  44 \fB\fB-a\fR\fR
  45 .ad
  46 .sp .6
  47 .RS 4n
  48 Report information about processes and users. In this mode \fBprstat\fR
  49 displays separate reports about processes and users at the same time.
  50 .RE
  51 
  52 .sp
  53 .ne 2
  54 .na
  55 \fB\fB-c\fR\fR
  56 .ad
  57 .sp .6
  58 .RS 4n
  59 Print new reports below previous reports instead of overprinting them.
  60 Long names are not truncated in this mode.
  61 .RE
  62 
  63 .sp
  64 .ne 2
  65 .na
  66 \fB\fB-C\fR \fIpsrsetlist\fR\fR
  67 .ad
  68 .sp .6
  69 .RS 4n
  70 Report only processes or lwps that are bound to processor sets in the given
  71 list. Each processor set is identified by an integer as reported by
  72 \fBpsrset\fR(1M). The load averages displayed are the sum of the load averages
  73 of the specified processor sets (see \fBpset_getloadavg\fR(3C)). Processes with
  74 one or more LWPs bound to processor sets in the given list are reported even
  75 when the \fB-L\fR option is not used.
  76 .RE
  77 
  78 .sp
  79 .ne 2
  80 .na


 113 .ne 2
 114 .na
 115 \fB\fB-j\fR \fIprojlist\fR\fR
 116 .ad
 117 .sp .6
 118 .RS 4n
 119 Report only processes or lwps whose project \fBID\fR is in the given list. Each
 120 project \fBID\fR can be specified as either a project name or a numerical
 121 project \fBID\fR. See \fBproject\fR(4).
 122 .RE
 123 
 124 .sp
 125 .ne 2
 126 .na
 127 \fB\fB-J\fR\fR
 128 .ad
 129 .sp .6
 130 .RS 4n
 131 Report information about processes and projects. In this mode \fBprstat\fR
 132 displays separate reports about processes and projects at the same time.
 133 A trailing asterisk marks a long name that has been truncated
 134 to fit the column.
 135 .RE
 136 
 137 .sp
 138 .ne 2
 139 .na
 140 \fB\fB-k\fR \fItasklist\fR\fR
 141 .ad
 142 .sp .6
 143 .RS 4n
 144 Report only processes or lwps whose task \fBID\fR is in \fItasklist\fR.
 145 .RE
 146 
 147 .sp
 148 .ne 2
 149 .na
 150 \fB\fB-L\fR\fR
 151 .ad
 152 .sp .6
 153 .RS 4n
 154 Report statistics for each light-weight process (\fBLWP\fR). By default,


 351 \fBID\fR may be specified as either a login name or a numerical user \fBID\fR.
 352 .RE
 353 
 354 .sp
 355 .ne 2
 356 .na
 357 \fB\fB-v\fR\fR
 358 .ad
 359 .sp .6
 360 .RS 4n
 361 Report verbose process usage. This output format includes the percentage of
 362 time the process has spent in user mode, in system mode, and sleeping. It also
 363 includes the number of voluntary and involuntary context switches, system calls
 364 and the number of signals received. Statistics that are not reported are marked
 365 with the \fB-\fR sign.
 366 .RE
 367 
 368 .sp
 369 .ne 2
 370 .na
 371 \fB\fB-W\fR\fR
 372 .ad
 373 .sp .6
 374 .RS 4n
 375 Truncate long names even when \fBprstat\fR would normally print them
 376 in full.
 377 A trailing asterisk marks a long name that has been truncated
 378 to fit the column.
 379 .RE
 380 
 381 .sp
 382 .ne 2
 383 .na
 384 \fB\fB-z\fR \fIzoneidlist\fR\fR
 385 .ad
 386 .sp .6
 387 .RS 4n
 388 Report only processes or LWPs whose zone ID is in the given list. Each zone ID
 389 can be specified as either a zone name or a numerical zone ID. See
 390 \fBzones\fR(5).
 391 .RE
 392 
 393 .sp
 394 .ne 2
 395 .na
 396 \fB\fB-Z\fR\fR
 397 .ad
 398 .sp .6
 399 .RS 4n
 400 Report information about processes and zones. In this mode, \fBprstat\fR
 401 displays separate reports about processes and zones at the same time.
 402 A trailing asterisk marks a long name that has been truncated
 403 to fit the column.
 404 .RE
 405 
 406 .SH OUTPUT
 407 .sp
 408 .LP
 409 The following list defines the column headings and the meanings of a
 410 \fBprstat\fR report:
 411 .sp
 412 .ne 2
 413 .na
 414 \fBPID\fR
 415 .ad
 416 .sp .6
 417 .RS 4n
 418 The process \fBID\fR of the process.
 419 .RE
 420 
 421 .sp
 422 .ne 2
 423 .na
 424 \fBUSERNAME\fR
 425 .ad
 426 .sp .6
 427 .RS 4n
 428 The real user (login) name or real user \fBID\fR.
 429 A trailing asterisk marks a long name that has been truncated
 430 to fit the column.
 431 .RE
 432 
 433 .sp
 434 .ne 2
 435 .na
 436 \fBSWAP\fR
 437 .ad
 438 .sp .6
 439 .RS 4n
 440 The total virtual memory size of the process, including all mapped files and
 441 devices, in kilobytes (\fBK\fR), megabytes (\fBM\fR), or gigabytes (\fBG\fR).
 442 .RE
 443 
 444 .sp
 445 .ne 2
 446 .na
 447 \fBRSS\fR
 448 .ad
 449 .sp .6
 450 .RS 4n