2 Replies Latest reply: Dec 29, 2012 5:36 PM by DBA112 RSS

    Duplicate target database - until time?

    DBA112
      Dear Experts,

      RDBMS - 10.2.0.4

      I'm trying to refresh Database "ORCL2" using a cold backup of "ORCL1", both databases are on diff servers. below is the time stamp ORCL1 backup finished:
      Finished Control File and SPFILE Autobackup at 12/27/2012 09:28:58
      Just wondering if clone will run without any issues with below command, please share your thoughts..
      run{
      ---channel allocation commands---
      duplicate target database to ORCL2
       until time "to_date('12/27/2012 09:28:58','mm/dd/yyyy hh24:mi:ss')";
      ---channel release commands---
      }
      Edited by: DBA112 on Dec 28, 2012 2:10 PM
        • 1. Re: Duplicate target database - until time?
          mseberg
          Hello;

          In theory it should work.

          "DUPLICATE recovers by default up to the last archived redo log generated at the time the command was executed, or until a time specified with a SET UNTIL clause."


          Source - Database Backup and Recovery Reference 10g Release 2 (10.2) Part Number B14194-03

          Doc Example
          DUPLICATE TARGET DATABASE TO newdb
              DB_FILE_NAME_CONVERT=('/h1/oracle/dbs/trgt/','/h2/oracle/oradata/newdb/')
              UNTIL TIME 'SYSDATE-1'  # specifies incomplete recovery
          ...
          Another Example

          http://blog.dbauniversity.com/2012/06/rman-duplicate-until-time.html

          Best Regards

          mseberg
          • 2. Re: Duplicate target database - until time?
            DBA112
            Thank you