6 Replies Latest reply on Jan 1, 2013 1:41 AM by DBA112

    RMAN Duplicate

    DBA112
      Dear Experts,

      RDBMS - 10.2.0.4, Trying to refresh database using RMAN duplicate. Took a cold backup of the source database - *"OLDDB"*.

      OLDDB backup log finishing lines - Finished Control File and SPFILE Autobackup at 12/31/2012 09:28:58.

      Can you help me understand the difference b/w the below 2 run blocks, first one is until time with exact time stamp - 09:28:58, second one just 9:28:00. Which of these is safe to use (not having to go through manual media recovery) . I need duplicate to run clean and open the database.

      Appreciate your help.

      run
      {
      duplicate target database to newdb
      until time "to_date('12/31/2012 09:28:58','mm/dd/yyyy hh24:mi:ss')";
      }
      
      
      run
      {
      duplicate target database to newdb
      until time "to_date('12/31/2012 09:28:00','mm/dd/yyyy hh24:mi:ss')";
      }
        • 1. Re: RMAN Duplicate
          mseberg
          Hello;

          09:28:58

          If you use the other based on your log piece you will not get the Control file or Spfile and you will probably have to deal with an error.

          Keep in mind the until or to restore point is always an incomplete recovery.

          Best Regards

          mseberg
          1 person found this helpful
          • 2. Re: RMAN Duplicate
            DBA112
            hi, Thanks for the response. I thought same. What happens if I use time - 9:29:00 in the until clause? Will it ask more arch logs for the recovery?
            • 3. Re: RMAN Duplicate
              mseberg
              I have never tried that on a duplicate.

              I would assume it would prompt for archive since it would know what archive is next and RMAN does on every other recovery I try.

              Best Regards

              mseberg
              1 person found this helpful
              • 4. Re: RMAN Duplicate
                DBA112
                Since, this is a cold backup.. I believe using set until time - 09:28:58, perfectly runs the duplicate and opens the database. Do you agree? I mean presuming that it not encounters some other error, from a set until time perspective, 9:28:58 should run perfect right?
                • 5. Re: RMAN Duplicate
                  mseberg
                  Hello again;

                  Yes, that is what I would do.

                  I tried to find in the docs where you could "Provide the archive RMAN needs" but so far I don't have an exact quote.

                  I will keep looking.

                  Best Regards ( and Happy New Year )

                  mseberg

                  Later

                  Found an interesting note comparing UNTIL TIME and UNTIL SCN

                  With UNITL TIME, the time gets evaluated twice for both restore and recovery. So if you are using SYSDATE (start after midnight).

                  Edited by: mseberg on Dec 31, 2012 7:36 PM


                  Still later

                  Kind of interesting :

                  http://oracle.su/docs/11g/backup.112/e10643/rcmsynta020.htm


                  The table here hints about RMAN asked for Archive.

                  Edited by: mseberg on Dec 31, 2012 7:40 PM
                  • 6. Re: RMAN Duplicate
                    DBA112
                    I will not be using SYSDATE, Instead, I will go with time stamp when control file auto backup finished.

                    Thanks for your help, Wish you a very Happy New Year too.