RE: RMAN recovery question...

  • From: "DIANNA GIBBS" <DIANNA.GIBBS@xxxxxxxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>,<Thomas.Mercadante@xxxxxxxxxxxxxxxxx>
  • Date: Thu, 25 Jan 2007 07:53:31 -0600

Thanks Tom.  I really appreciatete the information.  I did get it to
work last night.  Restored/recovered in about 2 hours.    Do you 
know of any RMAN best practices whitepapers?  I have both the 9i and
10g RMAN books but I'd like to get all of our bases covered before
I have time to read in more depth.





>>> "Mercadante, Thomas F (LABOR)"
<Thomas.Mercadante@xxxxxxxxxxxxxxxxx> 01/25/07 7:10 AM >>>
Dianna,

I think you are missing one more "allocate" statement.  You don't say
where you backed your database up to, but I always have two allocate
statements - one to read the backup set and one to write the stuff to
disk.

Secondly, you do not need to restore your controlfile unless they are
all lost.  Rman will work with the "set until" command and update your
current control files with the correct information.  This also means
that you do not need to delete all of the database files on disk -
Rman
will simply recreate or update them in place.  And it is smart enough
to
know what files/blocks to update and what datafiles and archivelog
files
to pull from you backup in combination with what archive files may be
currently on disk.

Below is my standard Rman Point in Time recovery script.  Before this
is
run the database has been started with the "startup nomount" option.
Notice that the first "allocate" command is used to read the
backupset.
This is either from disk or from 'SBT_TAPE' depending on where you
went
to.

If you are unsure in using these commands, create a small test
database
and run some Rman backups to disk.  Trash the database and perform
restores until you are confident in that it works.  Nothing like
testing
on something you can throw away before doing the real thing.

Hope this helps.

Tom

PS.  You need to perform a new Rman full backup when you are finished
recoverying!!

run{
  allocate channel d1 type disk;
  allocate channel d2 type disk;
  set until time
"to_date('2007-01-25:12:56:00','yyyy-mm-dd:hh24:mi:ss')";
  sql "alter database mount";
  restore (database);
  recover database;
  release channel d1;
  release channel d2;
  sql "alter database open resetlogs";
   }
reset database;



--------------------------------------------------------
This transmission may contain confidential, proprietary, or privileged
information which is intended solely for use by the individual or entity
to whom it is addressed.  If you are not the intended recipient, you are
hereby notified that any disclosure, dissemination, copying or
distribution of this transmission or its attachments is strictly
prohibited.  In addition, unauthorized access to this transmission may
violate federal or State law, including the Electronic Communications
Privacy Act of 1985.  If you have received this transmission in error,
please notify the sender immediately by return e-mail and delete the
transmission and its attachments.


-----Original Message-----

From: oracle-l-bounce@xxxxxxxxxxxxx 
[mailto:oracle-l-bounce@xxxxxxxxxxxxx] On Behalf Of DIANNA GIBBS
Sent: Wednesday, January 24, 2007 6:12 PM
To: oracle-l@xxxxxxxxxxxxx 
Subject: RMAN recovery question...

I'm new to RMAN and have a recovery question.  We're recovering
our test database to a point in time.  The database is around 60 gig.
When we start recovery, will RMAN re-create, restore and then 
recover all the database?  And this may be a stupid question,
but  if more-current files are there, is RMAN intelligent enough
to just restore the changed blocks?  It was a full on-line
backup.  And depending on the answer, should I delete all the old
files

or can I just leave them as is?  What about channels, can I allocate
more channels for a faster recovery?

Here's my script which I'm planning on doing command line:

rman target /
connect catalog rman_xxx@rcat

(password)

run {
     set until time "to_date('19-JAN-2007 18:00:00','DD-MON-YYYY
HH24:MI:SS')";
     allocate channel ch1 type disk;
     restore controlfile ;
     alter database mount ;
     restore database ;
     recover database ;
     release channel ch1;
    }


Check to make sure temp tablespace is there

alter database open resetlogs;




Thanks so much-
Dianna G.
--
//www.freelists.org/webpage/oracle-l 
--
//www.freelists.org/webpage/oracle-l 
--
//www.freelists.org/webpage/oracle-l


Other related posts: