Recovering catalog and directory objects

If you need to recover the catalog and directory, you must recover them before you recover user table spaces. Also, you must recover catalog and directory objects in a specific order.

Before you begin

Before you can recover catalog and directory objects, you must meet the following requirements:
  • Start of changeConverting page sets to or from extended 10-byte format during REBUILD INDEX on catalog and directory indexes complicates recovery and might cause failures. To avoid these failures, convert your catalog and directory indexes to extended 10-byte format before you might need to recover your catalog and directory objects.End of change
  • Recovering and rebuilding catalog and directory objects requires installation SYSADM or installation SYSOPR authority.
  • If you are performing a recovery at a remote site, start the remote Db2 for z/OS® subsystem with ACCESS(MAINT) specified on the START DB2 command and with DEFER ALL specified in the DSNZPARM load module. (See installation panels DSNTIPS and DSNTIPO3.) If Db2 is not started with ACCESS(MAINT), resource unavailable conditions on the real-time statistics (RTS) catalog indexes might occur during REBUILD INDEX(ALL) for the catalog and directory indexes.
  • If the logging environment requires adding or restoring active logs, restoring archive logs, or performing any action that affects the log inventory in the BSDS, you need to recover the BSDS before catalog and directory objects. To copy active log data sets, use the Access Method Services REPRO function.

A full recovery of the catalog and directory is recommended. However, if you need to do a point-time-recovery, be aware of the implications associated with doing point-in-time recovery of the catalog, directory, and user objects. See Point-in-time recovery of the catalog, directory, and all user objects.

About this task

The following table spaces do not have entries in SYSIBM.SYSLGRNX. The indexes that are associated with these table spaces also do not have entries in SYSIBM.SYSLGRNX, even if they were defined with COPY YES. These objects are assumed to be open from the point of their last image copy, so the RECOVER utility processes the log from that point forward.

  • DSNDB01.SYSUTILX
  • DSNDB01.DBD01
  • DSNDB01.SYSLGRNX
  • DSNDB06.SYSTSCPY
  • DSNDB01.SYSDBDXA
Requirement: You must recover the catalog and directory objects in the order that is specified in this task. If you are recovering any subset of the objects in the list, start with the object that is listed first and continue in the order of the list. For example, if you need to recover SYSLGRNX, SYSUTILX, and SYSUSER, recover SYSUTILX first, then SYSLGRNX, and then SYSUSER. You do not need to recover all of the objects; only recover those objects that require recovery.
General guidelines: Use the following general guidelines for all of the steps in this task:
  • If you copy your catalog or directory indexes, use the RECOVER utility to recover your indexes. Otherwise, use the REBUILD INDEX utility to rebuild those indexes.
  • For all catalog and directory table spaces, you can list the IBM®-defined indexes that have the COPY YES attribute in the same RECOVER utility statement.
  • Recovery of the items in the list can be done concurrently or included in the same job step. However, the following restrictions apply:
    • When you recover the following table spaces or indexes, the job step in which the RECOVER statement appears must not contain any other utility statements. No other utilities can run while the RECOVER utility is running.
      • DSNDB01.SYSUTILX
      • All indexes on SYSUTILX
      • DSNDB01.DBD01
    • When you recover the following table spaces, no other utilities can run while the RECOVER utility is running. Other utility statements can exist in the same job step.
      • DSNDB06.SYSTSCPY
      • DSNDB01.SYSLGRNX

Procedure

To recover catalog and directory objects:

  1. Recover DSNDB01.SYSUTILX.
  2. Run REBUILD INDEX(ALL) on DSNDB01.SYSUTILX.
  3. Recover DSNDB01.DBD01.
  4. Run REBUILD INDEX(ALL) on DSNDB01.DBD01.
  5. Recover DSNDB01.SYSDBDXA.
  6. Run REBUILD INDEX(ALL) on DSNDB01.SYSDBDXA.
  7. Recover DSNDB06.SYSTSCPY.
  8. Run REBUILD INDEX(ALL) on DSNDB06.SYSTSCPY.
  9. Recover DSNDB01.SYSLGRNX.
  10. Run REBUILD INDEX(ALL) on DSNDB01.SYSLGRNX.
  11. Recover DSNDB06.SYSTSSTG and DSNDB06.SYSTSVOL.
  12. Run REBUILD INDEX(ALL) on DSNDB06.SYSTSSTG and DSNDB06.SYSTSVOL.
  13. Recover all of the remaining catalog and directory table spaces in a single RECOVER utility statement with the PARALLEL option.

    The remaining catalog and directory table spaces include the following tables spaces:

    • The directory table spaces in DSNDB01:
      • SCT02
      • SPT01
      • SYSSPUXA
      • SYSSPUXB
    • The catalog table spaces that are listed in the following table:
      Start of change
      Table 1. Remaining catalog table spaces to recover after new function is activated
      Remaining catalog table spaces to recover after new function is activated
      SYSALTER
      SYSCONTX
      SYSDDF
      SYSEBCDC
      SYSGPAUT
      SYSGRTNS
      SYSHIST
      SYSJAUXA
      SYSJAUXB
      SYSJAVA
      SYSPLUXA
      SYSPLUXB
      SYSROLES
      SYSSEQ
      SYSSEQ2
      SYSSTATS
      SYSTARG
      SYSTSADT
      SYSTSASC
      SYSTSATS
      SYSTSATW
      SYSTSATX
      SYSTSAUX
      SYSTSCHX
      SYSTSCKD
      SYSTSCKS
      SYSTSCOL
      SYSTSCON
      SYSTSCTD
      SYSTSCTL

      SYSTSCTR
      SYSTSDAT
      SYSTSDBA
      SYSTSDBR
      SYSTSDBU
      SYSTSDEP
      SYSTSDQD
      SYSTSDQE
      SYSTSDQH
      SYSTSDQO
      SYSTSDQS
      SYSTSDQT
      SYSTSDQY
      SYSTSENV
      SYSTSFAU
      SYSTSFLD
      SYSTSFOR
      SYSTSICO
      SYSTSIPT
      SYSTSISH1
      SYSTSISS
      SYSTSIXC
      SYSTSIXR
      SYSTSIXS
      SYSTSIXT
      SYSTSTSH1
      SYSTSKEY
      SYSTSKYC
      SYSTSLVH
      SYSTSOBX

      SYSTSPDO
      SYSTSPDT
      SYSTSPEN
      SYSTSPHX
      SYSTSPKA
      SYSTSPKC
      SYSTSPKD
      SYSTSPKG
      SYSTSPKL
      SYSTSPKS
      SYSTSPKX
      SYSTSPKY
      SYSTSPLA
      SYSTSPLD
      SYSTSPLN
      SYSTSPLY
      SYSTSPRH
      SYSTSPRM
      SYSTSPTX
      SYSTSPVR
      SYSTSQRA
      SYSTSQRE
      SYSTSQRO
      SYSTSQRP
      SYSTSQRS
      SYSTSQRY
      SYSTSRAU
      SYSTSREL
      SYSTSROU
      SYSTSSCM

      SYSTSSES
      SYSTSSFB
      SYSTSSNL
      SYSTSSNX
      SYSTSSRG
      SYSTSSTA
      SYSTSSTM
      SYSTSSXL
      SYSTSSYN
      SYSTSTAB
      SYSTSTAU
      SYSTSTBC
      SYSTSTPF
      SYSTSTPT
      SYSTSTRG
      SYSTSTRT
      SYSTSTSP
      SYSTSTSS
      SYSTSUNI
      SYSTSVAD
      SYSTSVAR
      SYSTSVAT
      SYSTSVAU
      SYSTSVEW
      SYSTSVTR
      SYSTSVWD
      SYSTSVWT
      SYSTSXTM
      SYSTSXTS
      SYSUSER
      SYSXML
      End of change
      Note:
      1
      Start of changeIf versioning is not defined in the database, SYSTSISH and SYSTSTSH do not need to be recovered.End of change
  14. Run REBUILD INDEX(ALL) on DSNDB06.SYSTSISS and DSNDB06.SYSTSTSS.
  15. Run REBUILD INDEX(ALL) on DSNDB06.SYSTSTSP, DSNDB06.SYSTSTPT, and DSNDB06.SYSTSTAB.

    Execute the following utility statements to rebuild the IBM-defined and any user-defined indexes on the table spaces:

      REBUILD INDEX (ALL) TABLESPACE DSNDB06.SYSTSTSP            
                          RBALRSN_CONVERSION NONE                
      REBUILD INDEX (ALL) TABLESPACE DSNDB06.SYSTSTPT            
                          RBALRSN_CONVERSION NONE                
      REBUILD INDEX (ALL) TABLESPACE DSNDB06.SYSTSTAB            
                          RBALRSN_CONVERSION NONE
  16. Rebuild all of the remaining catalog and directory indexes using REBUILD INDEX(ALL) for each table space recovered in step 13. Rebuild all user-defined indexes on the catalog that have not been rebuilt or recovered yet.

Results

Messages that you might receive:

DSNT500I
An ID with a granted authority receives message DSNT500I RESOURCE UNAVAILABLE while trying to recover a table space in the catalog or directory if certain table spaces in the following list are unavailable:
  • DSNDB06.SYSTSFAU
  • DSNDB06.SYSTSCOL
  • DSNDB06.SYSTSTSP
  • DSNDB06.SYSTSTPT
  • DSNDB06.SYSTSTAB
  • DSNDB06.SYSTSIXS
  • DSNDB06.SYSTSIXT
  • DSNDB06.SYSTSIXR
  • DSNDB06.SYSTSIPT
  • DSNDB06.SYSTSREL
  • DSNDB06.SYSTSFOR
  • DSNDB06.SYSTSSYN
  • DSNDB06.SYSTSFLD
  • DSNDB06.SYSTSTAU
  • DSNDB06.SYSTSKEY
  • DSNDB06.SYSUSER

If you receive message DSNT500I, you must take one of the following actions:

  • Make these table spaces available.
  • Run the RECOVER utility on the catalog or directory by using an authorization ID that has the installation SYSADM or installation SYSOPR authority.
DSNT501I
If certain table spaces in DSNDB06 are unavailable when an ID with a granted authority tries to rebuild indexes in the catalog or directory, Db2 issues message DSNT501I.

What to do next

After you recover the Db2 catalog and directory, perform the following actions:

  • After a point-in-time recovery on the catalog and directory, run the CHECK DATA utility on the objects to ensure consistency.
  • Recover XML scheme repository objects. Although the XML schema repository database, DSNXSR, is not part of the Db2 catalog, you need to recover all table spaces in the DSNXSR database and rebuild all indexes on those table spaces immediately after you recover the Db2 catalog. If you perform a point-in-time recovery of the catalog, you need to recover objects in the DSNXSR database to the same point in time.