Sunday, March 11, 2018

RMAN Backup Error and Corruption of DatafileCopy

Symptom:

   Run restore preview to check sanity of rman backup and hit below error

run { 
ALLOCATE CHANNEL c1_tape DEVICE TYPE sbt_tape ;
RESTORE DATABASE PREVIEW;
RELEASE CHANNEL c1_tape;
} 

RMAN-06026: some targets not found - aborting restore
RMAN-06100: no channel to restore a backup or copy of datafile 98
RMAN-06100: no channel to restore a backup or copy of datafile 48
RMAN-06100: no channel to restore a backup or copy of datafile 7
 
Solution would be simple, we just manually tape backup the missing 3 files 
 run {
   ALLOCATE CHANNEL c1_tape DEVICE TYPE sbt_tape 
   backup copy of datafile 98; 
   backup copy of datafile 48;
   backup copy of datafile 7;
   release CHANNEL c1_tape ;
Then hit datafilecopy corruption error which is outstanding 

ORA-19566: exceeded limit of 0 corrupt blocks for file 48

Solution:

It is lucky we have only datafilecpy corrupted. Not a datafile corruption. DBV shows 4 blocks corruption.
LIST COPY OF DATAFILE 48 
DELETE COPY OF DATAFILE 48
BACKUP AS COPY DATAFILE 48;
then
BACKUP DEVICE TYPE SBT_TAPE COPY OF DATAFILE  48; 

No comments: