Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Restore & Recovery

Re: Restore & Recovery

From: y <y_at_y.com>
Date: Mon, 09 Sep 2002 03:44:56 GMT
Message-ID: <3D7C1915.F4687975@y.com>

Thanks, Howard.

"Howard J. Rogers" wrote:

> y wrote:
>
> > ORACLE 8i EE
> >
> > I have two questions about "Restore and Recovery":
> >
> > Q1. I create a database with ARCHIVELOG mode. When I lost one of my
> > data file (Users tablespace). During recovery phase, I have to:
> > SQL> startup mount
> > SQL> recovery database
> > SQL> alter database open
> > How does it means the whole database is available during recovery
> > process? During recovery phase, I can't open the database.
>
> Not sure what you're really asking here, but if you mean 'how can I perform
> a recovery of a datafile whilst the rest of the database is open for
> business as usual', then the answer is: at the mount stage, offline the
> datafile that is causing the problem; open what's left of the database, and
> then recover the problematic tablespace.
>
> For example:
>
> SQL> alter database datafile 6 offline;
> SQL> alter database open;
> SQL> host cp /backup/data06.dbf /true/location/data06.dbf
> SQL> recover datafile 6;
> SQL> alter tablespace BLAH online;
>
> The same approach can be taken when the loss of the datafile does not cause
> the database as a whole to crash. Hence, you can offline the relevant
> tablespace, and then recover it in the same way.
>
> >
> > Q2). Using RMAN
> > Why when I need to restore and recover a tablespace, I have to take
> > the tablespace "OFFLINE TEMPORARY".
>
> Because RMAN is about to restore a datafile on top of a potentially
> still-existing (though obviously unusable) datafile. If Oracle hasn't 'let
> go' of it by taking it offline, copying the backup version on top of it is
> going to be problematic at best.
>
> As to why 'offline TEMPORARY' -well, the 'temporary' keyword controls
> whether and what sort of checkpoint is issued. A standard 'offline' would
> attempt to checkpoint the datafile -but since we presumably know
> something's wrong with it (otherwise we wouldn't be attempting to recover
> it), why bother?
>
> > And when I need to restore and recover a datafile, I need only to
> > take the tablespace "OFFLINE IMMEDIATE"?
> >
>
> Immediate doesn't attempt a checkpoint at all. Temporary checkpoints if it
> can, but doesn't get upset if it can't. It doesn't make a whole heap of
> difference, actually.
>
> Regards
> HJR
>
>
> > Thanks in advance,
Received on Sun Sep 08 2002 - 22:44:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US