|
|
By using SYSGEN's file designators, you can redirect SYSGEN's input and output.
Redirecting SYSGEN's input and output enables you, for example, to issue
commands to SYSGEN using command files that can operate without user
intervention or interactive keyboard input.
SYSGEN uses three formal file designators for input, output, and listing:
SYSGIN. The formal file designator for the standard
SYSGEN input file. By default, this file is set to
$STDINX.
SYSGOUT. The formal file designator for the standard
SYSGEN output file. By default, this file is set to
$STDLIST.
SYSGLIST. The formal file designator for the standard
SYSGEN listing file. By default, this file is set to any device in
the class LP.
$STDINX and $STDLIST are the file names for the terminal from
which SYSGEN is run. The device in class LP is your system printer.
Redirect SYSGEN input and output by using the FILE command and equating
some other files to SYSGIN, SYSGOUT, and SYSGLIST,
or by using the INFO parameter and options in the SYSGEN
command line.
For example, the commands FILE SYSGIN=NEWIN and SYSGEN,,NEWIN
accomplish the same task. When SYSGEN is activated, they utilize NEWIN
as the input file. Likewise, the commands FILE SYSGOUT=NEWOUT and
SYSGEN,,,NEWOUT equate NEWOUT to the formal file designator,
SYSGOUT, so SYSGEN utilizes NEWOUT as the output file.
With redirection you can use a command input file to complete common routines
that you perform frequently. Example 4-9 lists a three-line job stream (named
SYSGENON) which, when run using the STREAM command, logs on
to the system, enters SYSGEN, and executes the SYSGEN command file
(LISTIT) in Example 4-10.
Refer to MPE/iX Commands Reference Manual for information on the
STREAM command.
Example 4-9 Command File (SYSGENON) Created With EDITOR
1 !JOB SYSGENON,MANAGER/userpass.SYS/acctpass,groupname
2 !SYSGEN,,LISTIT
3 !EOJ
Table 4-2 Actions Performed by Command File
Example explains the actions performed by each line of the preceding
command file.
Table 4-2 Actions Performed by Command File Example
Line |
Action |
1 | Log on to the file SYSGENON as MANAGER.SYS
with all accompanying system manager capabilities. |
2 | Activate SYSGEN and redirect input so that SYSGEN uses the
file named LISTIT as the input file. |
3 | End the job file after SYSGEN has completed the tasks
outlined by the SYSGEN command file LISTIT. |
Example 4-10 lists the contents of the command file (LISTIT), which,
when run, prints SYSGEN information on the system printer.
Example 4-10 SYSGEN Command File (LISTIT)
1 PERMYES ON
2 IO
3 LDEV DEST=OFFLINE
4 LPATH DEST=OFFLINE
5 LCLASS DEST=OFFLINE
6 OCLOSE
7 EXIT
8 EXIT
Table 4-3 Actions Performed by Command File
LISTIT explains the actions performed by the lines of the command file
example.
Table 4-3 Actions Performed by Command File LISTIT
Line |
Action |
1 | Set PERMYES ON. Recommended for all command
files. |
2 | Activate the IO configurator. |
3 | Send the characteristics of configured I/O devices to the
listing file SYSGLIST. |
4 | Send the characteristics of configured I/O paths to the
listing file. |
5 | Send the class name, class mode, and devices associated with
each class to the listing file. |
6 | Close (print) the listing file. |
7 | Exit the IO configurator. |
8 | Exit SYSGEN. |
When using SYSGEN in a noninteractive mode (such as a batch job or a command
file), certain conditions may occur that cause SYSGEN to ask for confirmation.
For example, if a KEEP is attempted on top of an already existing
configuration group, SYSGEN asks for confirmation. If no configuration exists,
no questions are asked.
When you set up the input to SYSGEN you may not know if the
question will be asked. To ensure the operation's success,
set PERMYES ON at the beginning of any set of noninteractive
commands as shown in step 1 above.
|