Let's understand Mainframe
Home Tutorials Interview Q&A Quiz Mainframe Memes Contact us About us

Module 1: Abend Codes


S222- Job Cancelled

S222 means the job or step was cancelled by someone or by the system - it is not a bug in your program.

What it means

  • The step was stopped deliberately before it finished - no dump analysis of program logic is needed.
  • S222 is an administrative event, so do not spend time debugging the program code.

Common causes

  • An operator issued the CANCEL command for the job or the step.
  • The job was cancelled on request from TSO/ISPF (for example, from the SDSF DA panel).
  • A JES operator command or automation cancelled the job.

How to find it

  • S222 is recorded with a reason in the SYSLOG and the job log - it tells who or what requested the cancel.
  • No program dump is needed; the log shows the cancel, not a program failure.

How to fix it

  • Find out why the job was cancelled - ask the operator or check the SYSLOG reason.
  • Fix the underlying reason (wrong job submitted, resource held too long) and resubmit the job.
  • Nothing in the program needs to be changed.

Example

  • The operator command that cancels a running job:-
    C MYJOB
  • After this command, the step abends with S222. A sample step:-
    //S222JOB JOB (ACCT),'CANCEL TEST',CLASS=A,MSGCLASS=X //STEP1 EXEC PGM=MYPROG //SYSOUT DD SYSOUT=*





© copyright mainframebug.com
Privacy Policy
MainframeBug Assistant