Monday, July 28, 2014

RMAN-03009: failure of delete command ... ORA-19606: Cannot copy or restore to snapshot control file

This error happen when a snapshot controlfile becomes obsolete, but rman is using it and cannot delete it. The problem that comes out of it is that all other obsolete backups are not deleted also since rman tries first to delete the controlfile copy.

Solution :

Take a note of the cuurent location of the snapshot controlfile and set a new location :

RMAN>show all;

RMAN configuration parameters for database with db_unique_name mydb;

.....

CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/myloc/mysnapc.f'; # OLD

RMAN>

RMAN>CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/mylocation/mysnapc.f'; # Configure new location


RMAN>host 'rm /myloc/mysnapc.f'; # delete old file from disk 

RMAN> corsscheck copy; # Mark the deleted file expired

RMAN> delete expired copy; # Delete the expired file from rman catalog/db control file

RMAN> CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/myloc/mysnapc.f'; # Restore to old location

RMAN>exit;

REFERENCES: Oracle Support Doc ID 1215493.1

No comments:

Post a Comment