Performing Miscellaneous eMS Functions
The CftS Batch Facility and error printouts are described below. CMS BATCH FACILITY The CMS Batch Facility is a function of CMS. It provides a vay of
entering individual user jobs through an active CMS machine from the
virtual card reader rather than from the console. The batch facility
reissues the IPL com.and after each job.
The CMS Batch Facility consists of tvo modules: DMSBTB, the bootstrap
routine (a nonrelocatable CMS module file) and DMSBTP, the processor
routine (a relocatable CMS text file that runs free storage).
The bootstrap module, DMSBTB, loads the processor routine DMSBTP and the
user exit routines BATEXIT1 and BATEXIT2 (if they exist) into free
storage. DMSBTB first ensures that DMSINS (eMS initialization) has set the BATRUI and BATLOAD flags on in the CMS nucleus constant area indicating
that either an explicit batch initial program load command has been
issued or that the CftSBATCH command has been issued immediately after
initial program load has taken place. If not, error message DMSBTB101E is typed and the batch console returns to a normal CftS interactive
environment. STATE (DMSSTT) is then called to confirm the existence of
the processor file DftSBTP TEXT. If the file does not exist, error
message DMSTBT100E is typed and the batch console returns to the cas interactive environment. Using the "state" copy of the file status table (FST) for DMSBTP, DMSBTB computes the size of TEXT file by multiplying the logical
record length by the nu.ber of logical records (no DS constants). A free storage request is made for the size of DMSBTP and the address of
the r9utine is then stored at ABATPROC in the NUCON area of the eMS nucleus.
The existence of the user exit routines is determined by STATE. If
they exist, their sizes are included in the request for free storage.
The free storage address is translated into graphic hexadecimal
for. at and the CMS LOAD command is issued to load the DMSBTP TEXT file
into the reserved free storage area. The user exit routines, BATEXITl TEXT and BATEXIT2 TEXT are also loaded at this time. If these files do
not exist, an unresolved external reference error code is returned by
the loader, but is ignored by DMSBTB because these routines are
optional. If an error (other than unresolved names) occurs, error
.essage DMSBTB101E is typed and the batch console returns to the ees interactive environment.
The loader tables are searched
point DMSBTPAB in the loaded batch
for the address of the ABEND entry
processor. When the entry is found, eMS Method of Operation and program organization 2-149
its address and that of entry DMSBTPLM are stored in ABATABND and the ABATLIftT respectively, in the NUCON area of the CftS nucleus. If the ABEID entry point is not found in the tables, error message is typed and the batch console returns to the CMS interactive
environment.
The BATLOAD flag is set off to show that DftSBTP has been loaded, the BATNOlX flag is set on to prevent user job execution until DMSBTP encounters a /JOB card and finally, control is returned to the command processor DftSINT. If an error message is issued, DMSERR is called to type the message,
and the BATRUN and BATLOAD flags are set off before control is returned
to CMS. This allows the normal CMS interaction to resume. The processoL .ouule DMSBTP simulates the of the CftS console read module DMSCRD. This is accomplished by issuing reads to
the virtual card reader, formatting the card-image record to resemble a
console record and returning control to CMS to process the command (or
data) request. DMSBTP also performs reads to the console stack if the
stack is not eapty, checks for and processes the /JOB card, ensuring
that it is the first record in the user job, traps all CP co •• ands to
.aintain system integrity and performs job initialization, cleanup, and
job recovery_ Upon receiving control, DMSBTP checks the BATCPEX flag in NUCON. If
the flag is set on, control was received from DftSCPF and a branch is
.ade to the CP trap routine to verify that the command is allowable
under batch. The function of that routine is described later. If the BATCPEX flag is off, control was received from DftSCRD (console read module) and DMSBTP checks for finished reads in the real batch console
stack. If the number of finished reads is not zero, control is returned
to DMSCRD to process the real console finished (stacked) reads. If the
nuaber of finished reads is zero, a record is read from the batch
virtual card reader into the CARD buffer via an SVC call to CARDBD (tMSCIO). The record in CARD buffer is typed on the console via the iRTERft macro. If the BATMOVE flag is set on (MOVEFILE executing from
the console), the records in the file are not typed on the console.
The record in the reader buffer is scanned to compute its length with
trailing blanks deleted. It is then aoved to the CftS console read
buffer and the computed length is stored in the original DftSCRD parameter list, whose address is passed by DftSCRD when it initially
passes control to DMSBTP. If the first user record is not a /JOB card, error message DMSBTP10SE is typed and normal cleanup is performed with the BATTERft flag set on.
This flag prevents another initial program load, since it is not needed
at this time. Reads to the card reader are then issued until the next /JOB card is found.
If the first record is a /JOB card, DMSBTP branches to its /JOB card
processing routine which calls DMSSCNN via a EALB. A check is made fer
the existence of the userid and account number on the card. If the
fields exist, a CP DIAGNOSE X'4C' is issued to start accounting
recording for that userid and account number. If an error is returned froa CP denoting an invalid userid, or if the userid or account number fields were missing on the /JOB card, error message DMSBTP106E is typed
and nor.a! cleanup is performed with the BATTERft flag set on. 2-150 IBft Vft/370 System Logic and Program Determination--Volume 2
Previous Page Next Page