This discussion is archived
4 Replies Latest reply: Oct 29, 2013 8:42 AM by TheFlaz RSS

RMAN recover copy of database problem - no copy of datafile x found to recover

TheFlaz Newbie
Currently Being Moderated

Hi

Either I'm not understanding something fundamental or something is wrong. I am creating a backup as copy for the purpose of migration to new storage. I entend to switch database to copy after recovering the copy when the database has been stopped and mounted.

 

Anyway, I create the copy with a tag and using a recovery catalog but when I try and recover the copy I get an error or message that 'no copy of datafile x found to recover'. Below are the commands I am using, abreviated for brevity. Any suggestions welcome, I have googled the hell out of this but not found anything that helps me. Any help appreciated.

 

Database Oracle 10.2.0.5 on HPUX using ASM. Recover catalog 11G

 

RMAN> RUN {

2>  BACKUP AS COPY DATAFILE 2 format '+DATA/DB/datafile/sysaux_001.dbf' tag XIV;

3>  BACKUP AS COPY DATAFILE 3 format '+DATA/DB/datafile/undo_001.dbf' tag XIV;

4>  BACKUP AS COPY DATAFILE 4 format '+DATA/DB/datafile/INDEXES_001.dbf' tag XIV;

5>  BACKUP AS COPY DATAFILE 5 format '+DATA/DB/datafile/TABLES_001.dbf' tag XIV;

6>  BACKUP AS COPY DATAFILE 1 format '+DATA/DB/datafile/system_001.dbf' tag XIV;

}

 

RMAN> list copy of database tag xiv;

List of Datafile Copies

Key     File S Completion Time Ckp SCN    Ckp Time        Name

------- ---- - --------------- ---------- --------------- ----

42435242 1    A 28-OCT-13       704934912  28-OCT-13       +DATA21/datafile/system_001.dbf

42435181 2    A 28-OCT-13       704934790  28-OCT-13       +DATA21/datafile/sysaux_001.dbf

42435220 3    A 28-OCT-13       704934840  28-OCT-13       +DATA21/datafile/undo_001.dbf

42435200 4    A 28-OCT-13       704934823  28-OCT-13       +DATA21r/datafile/indexes_001.dbf

42435038 5    A 28-OCT-13       704932252  28-OCT-13       +DATA21/datafile/tables_001.dbf

 

RMAN> recover copy of database with tag xiv;

Starting recover at 28-OCT-13

using channel ORA_DISK_1

no copy of datafile 1 found to recover

no copy of datafile 2 found to recover

no copy of datafile 3 found to recover

no copy of datafile 4 found to recover

no copy of datafile 5 found to recover

Finished recover at 28-OCT-13

 

Further RMAN info

 

RMAN> show all;

RMAN configuration parameters are:

CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default

CONFIGURE BACKUP OPTIMIZATION OFF;

CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default

CONFIGURE CONTROLFILE AUTOBACKUP ON;

CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default

CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default

CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default

CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default

CONFIGURE MAXSETSIZE TO UNLIMITED; # default

CONFIGURE ENCRYPTION FOR DATABASE OFF;

CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default

CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default

CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/oracle/product/10/2/DB/dbs/snapcf_xxx.f'; # default

  • 1. Re: RMAN recover copy of database problem - no copy of datafile x found to recover
    JohnWatson Guru
    Currently Being Moderated

    The syntax you need is BACKUP INCREMENTAL LEVEL 1 FOR RECOVER OF COPY if you want to recover the copy later.

  • 2. Re: RMAN recover copy of database problem - no copy of datafile x found to recover
    StefanKoehler Explorer
    Currently Being Moderated

    Hi,

     

    > I am creating a backup as copy for the purpose of migration to new storage. I entend to switch database to copy after recovering the copy when the database has been stopped and mounted.

    I think that you have misunderstood the purpose of the recover option "copy of". Oracle RMAN Documentation: RECOVER

    COPY OF

    Applies incremental backups to the specified image copy to roll it forward to any time equal to or before the most recent incremental backup of the file. The existing image copy is overwritten, and remains in a fuzzy state during the recovery. RECOVER COPY is a method for updating a copy and is not a media recovery of a current database file. This command is meant to be used in conjunction with the BACKUP... FOR RECOVER OF COPY syntax, to implement a strategy using incrementally updated backups. The following requirements must be met:

    * At least one copy of each datafile that you are recovering must exist.

    * Incremental backups taken after the image copy that you are recovering must exist.

    RMAN selects one suitable copy if there are multiple possible copies to which the incrementals can be applied to carry out the operation.

    Note: RMAN issues a warning (not an error) if it cannot recover to the specified time (or current time if none is specified) because no incrementals are available

     

    You should consider something like this, if you want to use the data file copies and perform a switch to the copy:

    RMAN> run
    { switch database to copy;
    recover database;
    }
    RMAN> alter database open;

     

    Regards

    Stefan

  • 3. Re: RMAN recover copy of database problem - no copy of datafile x found to recover
    Gamblesk Explorer
    Currently Being Moderated

    Did you do an incremental backup between the backup as copy and the recover command?

     

    If you did not you have nothing to recover with.

  • 4. Re: RMAN recover copy of database problem - no copy of datafile x found to recover
    TheFlaz Newbie
    Currently Being Moderated

    Thanks guys. I realise I wasn't fully understanding the concepts and will use the commands suggested

     

    A side question. Why does this new command......

     

    BACKUP INCREMENTAL LEVEL 1 FOR RECOVER OF COPY WITH TAG 'HORSE' DATAFILE 15 format '+DATA21_PRD01/database/datafile/horse_001.dbf';

     

    complete successfully but create the backup in the reco area rather than the format I suggest?

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points