RETURN-CODE, User, System, and RTS ABEND Handling

If a User, System, or RTS abend occurs in a job step, MFBSIJCL returns the decimal value of the user, system, or RTS status code by default. If this value is greater than 199, MFBSIJCL returns a final return code of 16 to the scheduler. Otherwise, the return code corresponds to the status code; for example, a user abend with return code 12 returns code 12.

Nevertheless, a USR, SYS, or RTS abend can return a specified return code to the scheduler. In the MFBSI configuration file, the parameters SYS-ABEND-RC, USR-ABEND-RC, and RTS-ABEND-RC can be set to force the OS return code to be returned to the scheduler in these cases.

Note: These parameters cannot be set on the command line for MFBSIJCL; they must be set in the configuration file.

This table shows some of the specific OS codes returned from MFBSIJCL.

Return Code Description
200-250

These values should be reserved for MFBSIJCL use.

They indicate an error specific to MFBSIJCL, such as MFBSI_DIR not set, unknown or missing parameters, or error during job submission (CASSUB/CASOUT).

See the topic on specific return codes issued by MFBSIJCL for descriptions of each return code.

208 JES/JCL error detected.
209 Job submission failed (See JobLog output).
211 Job ended, no numeric RC returned.
0-16 Usual error codes returned by Enterprise Server/MSS JCL (job execution).
0 JOB execution successful.
16 Unsuccessful JOB execution.

To see the full list of MFBSI-specific return codes, execute one of the following commands from an Enterprise Developer command prompt (Windows) or a UNIX command shell where $COBDIR is set.

mfbsijcl /rc
mfbsijcl -h
mfbsijcl -help
mfbsijcl -?
Note: The parameters are case insensitive, and may be specified using / or -.

In the job log written by MFBSIJCL, either in SJobId.Log, JOB#####.log, or via STDOUT, JCLSI messages provide additional information. For example:

JCLSI0013E JOB????? => Rc:213 Configuration parameter unknown in MFBSI.cfg
JCLSI0014E JOB????? Parameter: ES_Server=-rES
JCLSI0077I JOB Ended with OS RC=0213. 13:12:59
JCLSI0028E JOB????? => Rc:243 In MFBSI_DIR,"regionName.Started" not found.
JCLSI0077I JOB Ended with OS RC=0243. 14:09:33
JCLSI0050I JOB01039 IEFBR14 JOB Concluded. (SYS=00002054 Reason=00000000 )[Job abended] 14:12:38

where SYS 2054 (decimal) = x'806' (Program not found). System Abend.

JCLSI0050I JOB01209 MFJCLRC JOB Concluded.  (RTS=00000173 Reason=00000000 ) [Job abended]    12:33:38 	

where RTS 173 signals a called program not found.

The purpose of these messages is to allow additional scheduler error processing, if needed.

Notes:

  • If the decimal value of the JCL return-code is greater than 254, it is converted to the value 16, and returned to the scheduler. This is also true if the JCL return-code falls in the range 200 - 254 (which is reserved for MFBSIJCL use).
  • Micro Focus recommends to set SYS-ABEND-RC, USR-ABEND-RC and RTS-ABEND-RC in mfbsi.cfg to easily identify these kind of errors from a scheduler perspective. For example:
    SYS-ABEND-RC=21
    USR-ABEND-RC=22
    RTS-ABEND-RC=23