IMS status code

IMS status AO: Physical I/O error

IMS status code AO means IMS got a physical I/O error while reading or writing a database data set (BSAM, GSAM, VSAM or OSAM). The call couldn't complete because the data couldn't be read or written.

Other names for this code

Also written as status code AO, IMS AO, DL/I status AO, AO status code, IMS I/O error.

What it means

When a DL/I call needs a block or control interval that isn't in the buffer pool, IMS reads it from disk. When it changes data, IMS writes it back. If z/OS reports a physical error on that I/O, IMS can't trust the data, so it returns AO for the call.

IMS also records where the error is. For a read error, IBM's documentation says IMS creates an extended error queue element (EEQE) for the bad block. Later calls that need that block usually fail the same way until the data set is recovered. Calls that touch other parts of the database keep working.

Any call that has to read or write the data set can get AO. That includes GSAM calls. AO is an error, and it's almost never caused by the program itself.

Common causes

  • A disk or controller error, or a damaged track, on the volume that holds the data set.
  • The data set was damaged outside IMS. It was overwritten by a non-IMS job, or only partly restored, for example.
  • A VSAM data set has a broken index or control interval after an earlier failure.
  • The data set was moved or copied in a way that left its contents inconsistent with what IMS expects.

How to find the problem

  1. Look in the job log, or on the IMS master console for an online system, for the IMS message that reports the I/O error. It names the database and DD.
  2. Look in the z/OS system log for hardware I/O error messages, such as IOS000I, at the same time and for the same volume.
  3. Use the DBRC LIST.DBDS command for the database data set to see whether IMS has recorded EEQEs for it.
  4. For a VSAM KSDS, run IDCAMS EXAMINE to check the index and data components.

How to fix it

  • Have your storage team check the device and move the data set if the volume is failing.
  • Recover the data set with the Database Recovery utility from the latest image copy and the logs since then, using your normal recovery procedure.
  • After recovery, start the database again and rerun the job or transaction that failed.
  • If the error was in a GSAM or other sequential input file, recreate the file and rerun the step.
  • Take regular image copies so recovery has a recent starting point.

IBM documentation

IBM documentation: status AO. Use the documentation for your installed release.

Report a correction to WND Software.

Questions

Is AO caused by my program?

Almost never. AO means the data set couldn't be read or written at the hardware or access-method level. The program just made the call that needed that block.

Will other calls against the database still work?

Usually, if they don't need the damaged block. IMS records the bad block and fails calls that need it until the data set is recovered.

What is an EEQE?

An extended error queue element. IMS uses it to remember that part of a database data set has an I/O error, so it doesn't use that data until it is recovered.