MainframeKit

S237

Tape block count mismatch at end of volume (IEC023I)SYSTEM ABEND

At the end of a tape volume, the number of blocks the system counted does not match the tape. Find out which count is right before rerunning.

MOST LIKELY

The drive or tape dropped a block, so the hardware count is wrong.

FIRST CHECK

Read IEC023I and, if present, IEC537I with its DEVICE and DCB counts.

TRY IT ▸

Block size and space calculator

What it means

Abend 237 comes with message IEC023I during end-of-volume processing. The system keeps a block count in the DCB as it reads or writes, and checks it against the tape. If they disagree, it ends the task rather than risk losing or duplicating data.

Message IEC537I often appears just before it and shows two counts: DEVICE (what the hardware reports) and DCB (what the system tracked). Return code 0C means the block count implied by the tape position does not match the DCB count.

Typical causes

  • The drive or tape dropped a block, so the hardware count is wrong.
  • Software lost track of the count, often an EXCP program that does not update DCBBLKCT.
  • Two systems used the same drive without serialization, so the tape was rewound mid-write.
  • A channel or interface error during the write.

How to fix it

  1. Read IEC023I and, if present, IEC537I with its DEVICE and DCB counts.
  2. Map the tape with a utility to find the true number of blocks.
  3. If the true count matches the DCB value, suspect the drive or tape; rerun on another drive.
  4. If it matches the DEVICE value, suspect the program or access method; check any EXCP code updates the block count.
  5. If the label was overwritten, check how drives are shared between systems.

Example

Illustrative only; names and values are invented.

IEF450I TAPEJOB2 STEP010 - ABEND=S237 U0000 REASON=0000000C