1 WHO

 Displays information about current processes.  Processes may be
 selected for display by using the optional parameter or quali-
 fiers.  Some performance measurements are possible with the /IO
 and /CPU qualifiers.

 Format:

	WHO [username,...] [/qualifier(s)]

 If more than one selection criterion is used, any process that
 matches any criterion will be displayed.

2 parameter

 [username,...] is one or more usernames separated by commas.
 Each  is a string of 1 to 12 characters identifying the
 username whose processes are to be displayed. Usernames may be
 abbreviated. If omitted, username is not used to select which
 processes are displayed. 

 If this parameter is a dot ("."), the controling process
 ("*self*") will be selected.

 There is both a parameter and a qualifier for username.  Both
 have the same effect.  If both are specified, the parameter is
 used and the qualifier is ignored.

2 CPU_time

 The default CPU time format uses only the most significant 4
 digits of the CPU time.  These digits are displayed in a 6
 character field with one of the following formats (depending
 on the bracket the time fits in):

   0 00:00:00.00 to    0 00:00:59.99 format 59.99s
   0 00:01:00.00       0 00:59:59.99        59m59s
   0 01:00:00.00       0 23:59:59.99        23h59m
   1 00:00:00.00      99 23:59:59.99        99d23h
 100 00:00:00.00    9999 23:59:59.99         9999d

 To display the CPU time in fully expanded form use the /CPU
 qualifier.

2 Modes
 Modes are displayed as a single character under the heading "M".
     B = BATCH
     I = INTERACTIVE
     N = NETWORK
   " " = OTHER

2 return_status
 The final return status, symbol $STATUS, has the number
 of processes found encoded.  The return status is a 32 bit
 number formatted as follows:
        31 28          16             2 0
         ...:...:...:...:...:...:...:...:
         :  :           :           : : :
          \/ ----\/----- -----\/---- * \/
      (31:28)  (27:16)      (15:4)   3 (2:0)
        cntrl    not        proc       severity
                 used       count
                                    bit 3 not used

 The process count can be derived from the $STATUS symbol using
 some simple DCL arithmetic: 
 	$ PROC_COUNT = ($STATUS .AND. %XFFF0) /256

 The severity field will contain 001 (success) if all selected
 processes are found and 100 (severe error) if any selections
 are not found.  In that case, WHO will display an error
 message: 
 	%WHO-F-NOTFND, nn selected but not found.

 The "cntrl" field will always contain 0001 which prevents VMS
 from attempting to convert the status code to a message.

2 qualifiers
/CPU

 /CPU

 The presence of this qualifier causes a separate line to be
 displayed showing CPU time in fully expanded (16 character)
 form, 0000 00:00:00.00.  And, the cycle duration is divided by
 the incremental CPU time to produce percentage of CPU
 utilization. 

 This qualifier implies /INTERVAL.

/FULL

 /FULL
 /NOFULL	(D)

 Specifies whether the full image file-spec is to be displayed
 on a second line.  This qualifier is not dependent on the
 /IMAGE qualifier.

/IMAGE

 /IMAGE=(image_name,...)

 If this is present, processes executing the specified images
 will be displayed.  If omitted, image name is not used to
 select which processes are displayed. An image_name is 1 to 9
 characters in length. Image_names may be abbreviated. To
 display the entire image name,
 DEVICE:[DIRECTORY]NAME.TYPE;VERSION, use the /FULL qualifier. 
 If only one image name is specified the parentheses may be
 omitted.

/INCREMENTAL

 /INCREMENTAL

 Presence of this qualifier causes the I/O counts and CPU times
 to be displayed only for the interval just
 completed.  The previous values are subtracted from the current.
 By default counts are cumulative, not incremental.

 This qualifier implies /INTERVAL.

 Note that it is possible for one process to log out and another to
 log in in the same slot producing erroneous counts for one interval.
 No attempt is made to detect this.

/INTERVAL

 /INTERVAL[=seconds]

 Causes the display to be repeated at the specified interval.
 If this qualifier is given with no value, the interval defaults
 to 10 seconds.  If this qualifier is omitted, the display is
 output only once.  Some other qualifiers imply /INTERVAL.

 Use <CONTROL-C> to exit WHO/INTERVAL.

/IO

 /IO

 The presence of this qualifier causes a separate line to be
 displayed showing buffered, and direct I/O counts, and the sum
 of those two in both cumulative and incremental form.

 This qualifier implies /INTERVAL. 

/MODE

 /MODE=(mode,...)

 If this is present, processes in the specified modes will be
 displayed.  If omitted, mode is not used to select which
 processes are displayed.  If only one mode is specified, the
 parentheses may be omitted.

 Mode may be any one of the following: INTERACTIVE, BATCH,
 NETWORK, or " ".  Only the first character is used for
 comparison. 

/OKNONE

 /OKNONE

 Indicates that the program should continue when the process
 count is zero.  By default WHO will exit if the process count
 is zero.  This qualifier has no meaning unless the /INTERVAL
 qualifier is present.

/PHYSICAL

 /PHYSICAL	(D)
 /NOPHYSICAL

 Controls whether the physical or virtual terminal name is
 displayed.  The physical terminal name is obtained from the
 $GETDVI system service.  The virtual terminal name is obtained
 from the $GETJPI system service.  In some cases these are the
 same.  /NOPHYSICAL is equivalent to /VIRTUAL.

/PID

 /PID=(process_id,...)

 If this is present, the processes with the specified process
 identifiers will be displayed.  If omitted, process_id is not
 used to select which processes are displayed.  If only one
 PID is specified, the parentheses may be omitted.

/PROCESS_NAME

 /PROCESS_NAME=(process_name,...)

 If this is present, processes with the specified process names
 will be displayed.  Process_name may be abbreviated.  If
 omitted, process name is not used to select which processes are
 displayed.  If only one process name is specified, the
 parentheses may be omitted.  Process_names are 1 to 15
 characters in length. 

/SCROLL

 /SCROLL	(D)
 /NOSCROLL

 Controls whether the display is scrolled or overwritten.  This
 qualifier will be effective only if the output terminal is a
 VT52 or VT100 and the /INTERVAL qualifier is present.

/SSSTAT

 /SSSTAT

 Causes the system service $GETJPI return status to be displayed
 for each call.

/STATE

 /STATE=(process_state,...)

 If this is present, processes in the specified states will be
 displayed.  Process_state may be abbreviated.  If omitted,
 state is not used to select which processes are displayed. If
 only one process state is specified, the parentheses may be
 omitted. 

 The following are valid process states: COLPG, MWAIT, CEF, PFW,
 LEF, LEFO, HIB, HIBO, SUSP, SUSPO, FPG, COM, COMO, CUR.  Any
 other value given will not be found.

/TERMINAL

 /TERMINAL[=(ddcu,...)]
 /NOTERMINAL

 If this is present, the terminal field will be used to select
 which processes are displayed.

 /TERMINAL without a value will cause all processes with a
 non-blank terminal field to be displayed.  /NOTERMINAL will
 cause the display of all processes with a blank terminal field.
 If the value is present, only processes with the specified
 terminals will be displayed.  [=ddcu] must be a standard VMS
 device-controller-unit specification (such as TTB3).  [=ddcu]
 may be abbreviated.  If only one terminal is specified, the
 parentheses may be omitted. 

/USERNAME

 /USERNAME=(username,...)

 If this is present, processes with the specified usernames
 will be displayed.  Username may be abbreviated.  If omitted,
 username is not used to select which processes are displayed.
 If only one username is specified, the parentheses may be
 omitted.  Username is a string of 1 to 12 characters.

 If username is a dot ("."), the controling process ("*self*")
 will be selected. 

 There is both a parameter and a qualifier for username.  Both
 have the same effect.  If both are specified, the parameter is
 used and the qualifier is ignored.

/VIRTUAL

 /VIRTUAL
 /NOVIRTUAL	(D)

 Controls whether the physical or virtual terminal name is
 displayed.  The physical terminal name is obtained from the
 $GETDVI system service.  The virtual terminal name is obtained
 from the $GETJPI system service.  In some cases these are the
 same.  /VIRTUAL is equivalent to /NOPHYSICAL.

