Wednesday, June 22, 2011

Point in Time Rman Restore from tape backup.

Point in time recovery after dropping existing database.
Requirements: Rman backup log file
SQL> startup nomount
RMAN> set DBID 1194164416;
RMAN> run {
ALLOCATE CHANNEL c1 DEVICE TYPE 'SBT_TAPE' PARMS 'SBT_LIBRARY=/usr/openv/netbackup/bin/libobk.so64.1';
SET CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE 'SBT_TAPE' TO '%F';
restore controlfile from 'backup piece name';  Eg: f6mfa3bj_1_1  , from backup log file;
}

RMAN> alter database mount;
RMAN> restore database from tag ='Tag number from backup log file'; eg: 'TAG20110619T190015';
RMAN>{ set SET UNTIL TIME 'Jun 19 2011 20:00:17';
 recover database from tag ='TAG20110619T193704';     (archive logs backup tag #)
}

SQL> alter database open resetlogs;

No comments:

Post a Comment