DB2

DB2 COPY PENDING status and recovery

DB2 COPY PENDING (COPY) restrictive status indicates that the affected object must be copied.

Causes of COPY PENDING status

  • If you load with LOG NO and do not take an inline copy (failed to include NOCOPYPEND), LOAD places a table space in the COPY-pending status.
  • The copy pending status will appear when image copies job fails while copying the data to Tape or DASD.
  • A state in which, an Image Copy on a table needs to be taken

Resolve COPY PENDING status

  • Run the Dummy image copy job and the Tablespace status changes from copy pending to RW (READ/WRITE).
  • If you dont want to take image copy, you can run Repair Utility
    //STEP01 EXEC DSNUPROC
    REPAIR SET TABLESPACE dbname.tsname NOCOPYPEND
  • Execute following db2 command to bring the status of tablespace to RW (READ/WRITE).
    START DATABASE(dbname) SPACE(tablespace-name) ACESS(FORCE)

DB2 COPY PENDING EXAMPLE

Following jobs remove copy pending and recovery pending status from a tablespace and removes copy pending, recovery pending status, and rebuild pending status from an index space

//STEPO1 EXEC PGM=DSNUTILB,REGIONM, 
// PARM='DB2X,MIGRDAN, '
//STEPLIB DD DSN=XXX.XXXXX.SDSNLOAD,DISP=SHR
//SYSIN DD *    
REPAIR SET TABLESPACE XXXXX.XXXXX NOCOPYPEND 
REPAIR SET TABLESPACE XXXXX.XXXXX NORCVRPEND
REPAIR SET INDEX XXXXX.XXXXX NOCOPYPEND
REPAIR SET INDEX XXXXX.XXXXX NORCVRPEND
REPAIR SET INDEX XXXXX.XXXXX NORBDPEND
/*
//SYSPRINT DD SYSOUT=* 
//UTPRINT DD SYSOUT=*

DB2 COPY Utility

The COPY online utility creates up to four image copies of any of the following

objects: table space, table space partition, data set of linear table space, index

space, or index space partition.

The two types of image copies are:

  • A full image copy, which is a copy of all pages in a table space, partition, dataset, or index space.
  • An incremental image copy, which is a copy only of those data pages that have been modified since the last use of the COPY utility and system pages.

The RECOVER utility uses these copies when recovering a table space or index

space to the most recent time or to a previous time. Copies can also be used by the

MERGECOPY, RECOVER, COPYTOCOPY, and UNLOAD utilities.

Read DB2 blogs: Click Here IBM DB2 Manual: Click Here

Admin

Share
Published by
Admin

Recent Posts

Increase Transparency and Collaboration Product Backlog

A well-maintained product backlog is crucial for successful product development. It serves as a single…

2 months ago

Product Backlog – Incremental value to the customer

Incremental value to the customer refers to the gradual delivery of small, functional parts of…

2 months ago

Product Market, Customer’s Desire, Need, and Challenges

A Product Market refers to the group of potential customers who might be interested in…

2 months ago

PAL-EBM Professional Agile Leadership – EBM Certification

The Professional Agile Leadership - Evidence-Based Management (PAL-EBM) certification offered by Scrum.org is designed for…

5 months ago

PAL I Professional Agile Leadership Certification

The Professional Agile Leadership (PAL I) certification, offered by Scrum.org, is designed to equip leaders…

5 months ago

Scrum Master Certification: CSM, PSM, SSM

Choosing the right Scrum Master Certification depends on your current experience and career goals. If…

7 months ago