Fetch information on console and authorized user programs
Component: | BS2000 |
Functional area: | Operator terminal control |
Domain: | CONSOLE-MANAGEMENT |
Privileges: | OPERATING |
Routing code: | @ |
Function
This command supplies operators with the following information:
device mnemonics for operator consoles or authorization names for authorized user programs
station and processor names of available authorized user programs
set of routing codes
availability of consoles and authorized user programs
current main console
If entered from a user task with OPERATING privilege, the command supports structured output in S variables (see "Output in S variable").
Format
SHOW-CONSOLE-STATUS |
Operands
CONSOLE = *OWN / *ALL(...) / list-poss(216): <alphanum-name 2..2> / <name 4..4>
Selects the consoles and authorized user programs for which status information is required.
CONSOLE = *OWN
Status information is required for the command issuer’s own console.
CONSOLE = *ALL(...)
Status information is required for all consoles and authorized user programs.
TYPE = *ANY
The information is output for all consoles and authorized user programs.
TYPE = *PHYSICAL
This information is output for consoles only.
TYPE = *LOGICAL
This information is output for authorized user programs only.
STATE = *ANY
This information is output irrespective of the state.
STATE = *OPERABLE
Information is only output for consoles or user programs ready for operation.
STATE = *INOPERABLE
Information is only output for consoles or user programs not ready for operation (status INOP).
CONSOLE = list-poss(216): <alphanum-name 2..2> / <name 4..4>
Up to 216 mnemonic console names (2-character) or names of authorized applications (4-character) can be specified.
Return codes
(SC2) | SC1 | Maincode | Meaning |
---|---|---|---|
0 | CMD0001 | Command executed successfully | |
2 | 0 | NBR1074 | Some of the specified console names not found. Commando only partially executed |
1 | CMD0202 | Syntax error in command | |
2 | CMD0198 | Shutdown in progress | |
32 | CMD2009 | Error on output to structured S variable | |
64 | CMD0216 | Required authorization not available | |
64 | NBR1073 | None of the specified console names found. |
Notes
In interactive mode, [K2] may be used as an interrupt key. In this case no return code is supplied.
The station and processor name information for an authorized user program allows operators to disconnect the identified user program (command /BCCONN PARTNER= (NEA,<station-name><processor-name>); see the “BCAM” manual [2]).
Results
Each time the command is entered, the following message is issued:
NBR1071 MAIN CONSOLE IS '(&00)'
In conjunction with the Operator LOGON function: if the physical main console has implicitly gained additional message output routing codes owing to the non-availability of other consoles, the following message is also issued:
NBR1054 CONSOLE ‚(&00)‘ IMPLICIT CODES: '(&01)'
In the case of physical consoles, the following additional message is output:
NBR1052 CONSOLE '(&00)' ASSIGNED CODES: '(&01)'
If the console is not assigned any routing codes, the value of Insert 01 is “NONE”.
If the routing code set of a physical console has been temporarily extended because that console is currently acting as substitute for other unavailable physical consoles, the following message indicates the temporary additions:
NBR1053 CONSOLE '(&00)' TEMPORARY CODES: '(&01)'
If the Operator LOGON function is used, message NBR1053 does not appear.
If an operator has logged on at a physical console, the operator ID is included in the following message:
NBR1078 CONSOLE '(&00)' OPERATOR-ID '(&01)'
If a physical console is defective (INOP) or has been switched off (OFF) with the command CONSOLE SWITCH, OFF=<mn>, or if no operator has logged on there (INACTIVE), this is indicated by the following message:
NBR1077 CONSOLE '(&00)' STATES: (&01)
The value of Insert 01 may be “INOP”, “OFF” or “INACTIVE”. INACTIVE is possible only in conjunction with the Operator LOGON function, in which case OFF is not possible. If the INOP state applies, the INACTIVE state is not displayed; but the combination of INOP and OFF is possible.
The following message reports the routing codes assigned to each authorized user program selected:
NBR1051 APPLICATION '(&00)' CODES: '(&01)'
If the authorized user program is not assigned any routing codes, the value of Insert 01 is “NONE”.
If an authorized user program is unavailable, the following message is issued:
NBR1076 APPLICATION '(&00)' STATES: '(&01)'
The value of Insert 01 may be “INOP”.
The following message reports on connected authorized user programs:
NBR1075 APPLICATION '(&00)' PROCESSOR '(&01)' STATION '(&02)'
If an operator has logged on to a user program with dynamic authorization names, the operator ID is included in the following message:
NBR1079 APPLICATION '(&00)' OPERATOR-ID '(&01)'
If consoles or authorized user programs have been explicitly specified and the given names do not exist, message NBR1072 is issued for each nonexistent name.
If CONSOLE=*ALL is specified, the number of unavailable authorized user programs is indicated by the following message:
NBR1058 /SHOW-CONSOLE-STATUS: (&00) FUTHER APPLICATIONS WITH DYNAMICAL
AUTHORIZATION NAMES ARE NOT CONNECTED
Output in S variable
The CONSOLE operand identifies the S variables which are to be created. The following specifications are possible for CONSOLE:
Notation used in command | Abbreviated form used in table |
---|---|
CONSOLE=*ALL | 1 |
CONSOLE=<alphanum-name 2..2> (corresponds to console) | 2 |
CONSOLE=<name 4..4> (corresponds to user program) | 3 |
CONSOLE=*OWN | 4 |
The command allows consoles and authorized user programs to be included together in a list. In this case all the S variables are generated.
Output information | Name of the S variable | T | Contents | Condition |
---|---|---|---|---|
Availability of the authorized user program | var(*LIST).APPL(*LIST).CONN-STA | S | *CONN | 1.3 |
Routing code of the authorized user program | var(*LIST).APPL(*LIST).NAME | S | ’’ <application-name> | 1.3 |
Operator ID (*) | var(*LIST).APPL(*LIST).OPER-ID | S | <operator-id> | 1.3 |
Processor name of the authorized user program | var(*LIST).APPL(*LIST).PROCESSOR-NAME | S | ’’ | 1.3 |
Routing code for authorized user program | var(*LIST).APPL(*LIST).ROUT-CODE(*LIST) | S | ’’ <routing-code> | 1.3 |
Station name of the authorized user program | var(*LIST).APPL(*LIST).STATION-NAME | S | ’’ | 1.3 |
Status of the console | var(*LIST).CONS(*LIST).OPERABLE-STA | S | *INOP | 1.2 |
Operator ID (*) | var(*LIST).CONS(*LIST).OPER-ID | S | <operator-id> | 1.2 |
Routing code for console | var(*LIST).CONS(*LIST).ROUT-CODE(*LIST) | S | ’’ | 1.2 |
Mnemonic device name of the console | var(*LIST).CONS(*LIST).UNIT | S | <mnemo-name> | 1.2 |
Implicit routing code | var(*LIST).IMPL-ROUT-CODE(*LIST) | S | <routing-code> | NBCONOPI=Y |
Mnemonic device name of the main console | var(*LIST).MAIN-CONS-UNIT | S | <mnemo-name> | |
Routing code for user task with OPR privilege | var(*LIST).TASK(*LIST).ROUT-CODE(*LIST) | S | ’’ <routing-code> | 4 |
TSN of the user task with OPR privilege | var(*LIST).TASK(*LIST).TSN | S | <tsn> | 4 |
(*) | For physical consoles and authorized user programs 8 blanks are output as the operator ID if the “operator logon” function is not used or if nobody has logged on as the operator. The same contents are also output for authorized user programs with static authorization names. |
Examples
/decl-var var-name=var(type=*structure),multiple-elem=*list
/exec-cmd (show-console-status console=@002),text-output=*none,strucoutput=var
/show-var var,inf=*par(val=*c-literal)
VAR(*LIST).MAIN-CONS-UNIT = 'C0' VAR(*LIST).APPL(*LIST).NAME = '@002' VAR(*LIST).APPL(*LIST).CONN-STA = '*CONN' VAR(*LIST).APPL(*LIST).STATION-NAME = 'BT200226' VAR(*LIST).APPL(*LIST).PROCESS = 'D016ZE07' VAR(*LIST).APPL(*LIST).OPER-ID = 'TSOS ' VAR(*LIST).APPL(*LIST).ROUT-CODE(*LIST) = ''
/exec-cmd (show-console-status console=C0),text-output=*none,struc-output=var
/show-var var,inf=*par(val=*c-literal)
VAR(*LIST).MAIN-CONS-UNIT = 'C0' VAR(*LIST).CONS(*LIST).UNIT = 'C0' VAR(*LIST).CONS(*LIST).OPERABLE-STA = '*OPERABLE' VAR(*LIST).CONS(*LIST).OPER-ID = ' ' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '*' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'A' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'B' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'C' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'D' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'E' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'F' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'G' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'H' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'I' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'J' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'K' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'L' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'M' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'N' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'O' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'P' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'Q' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'R' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'S' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'T' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'U' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'V' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'W' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'X' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'Y' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = 'Z' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '0' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '1' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '2' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '3' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '4' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '5' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '6' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '7' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '8' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '9' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '$' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '#' VAR(*LIST).CONS(*LIST).ROUT-CODE(*LIST) = '@