Previous Topic Next topic Print topic


Rebuilding Corrupted Databases

When a database file has become corrupt, you must re-build it. This situation is rare, but can occur if, for example, the file was open during a system crash.

To rebuild a corrupted database, use JCL submission executing the database utility program: MFDBUJCL

With MFDBUJCL:

Note:
  • If a database file requires a rebuild, then you should consider whether any associated index files should be rebuilt as well.
  • Make sure that there is enough free space on disk before submitting the rebuild job.

    You will need as much space as the file to be rebuilt requires, and if you have specified an OUTPUT file to be created in the same directory, then you need to account for the extra space requirement.

An example of JCL for restoring a corrupted database is below:

  //DBUJCL01 JOB 'IMS DATABASE UTILITY',CLASS=A,MSGCLASS=A
//*--------------------------------------------------------------------
//* Copyright (C) 1991-2010 Micro Focus (IP) Limited.
//* All rights reserved.
//*-------------------------------------------------------------------
//*
//* THIS JOB REBUILDS THE IMS DEMONSTRATION DATABASE
//* 'DBDNP' USING THE IMSDBU JCL INTERFACE MFDBUJCL.
//*
//*
//STEP01  EXEC PGM=MFDBUJCL,PARM='REBUILD'
//SYSOUT  DD SYSOUT=*
//SYSIN   DD *
INPUT=DBDNP.DAT
OUTPUT=DBDNP.OUT.DAT
/*     
//
Previous Topic Next topic Print topic