SCN Based Recovery
1.On the new physical standby, determine the current scn:
SQL> SELECT TO_CHAR(CURRENT_SCN) FROM V$DATABASE;
CURRENT_SCN
-----------
900117
2.On the new primary database, create an incremental backup based on the current SCN of the standby and a new standby control file:
Connect to rman :
% rman target /
RMAN> backup incremental from scn 900117 database format '/home/oracle/u01/%U';
RMAN> backup device type disk format '/home/oracle/u01/%U' current control file for standby;
3.Transfer all backup pieces generated by the above command to the standby host.
% scp /home/oracle/u01/04m2vv18_1_1:`pwd`
4.Connect to the new physical standby as the RMAN target to do the following:
restore the standby controlfile,
catalog the standby datafiles and backup pieces,
and switch the standby controlfile to the standby datafile copies
% rman target /
RMAN> startup nomount force;
RMAN> restore standby controlfile from '/home/oracle/u01/0hm30a85_1_1';
RMAN> alter database mount;
RMAN> catalog start with '+DATA/titans_stby';
RMAN> switch database to copy;
RMAN> recover database noredo;
5.Restart managed recovery.
SQL> recover managed standby database using current logfile disconnect;
1.On the new physical standby, determine the current scn:
SQL> SELECT TO_CHAR(CURRENT_SCN) FROM V$DATABASE;
CURRENT_SCN
-----------
900117
2.On the new primary database, create an incremental backup based on the current SCN of the standby and a new standby control file:
Connect to rman :
% rman target /
RMAN> backup incremental from scn 900117 database format '/home/oracle/u01/%U';
RMAN> backup device type disk format '/home/oracle/u01/%U' current control file for standby;
3.Transfer all backup pieces generated by the above command to the standby host.
% scp /home/oracle/u01/04m2vv18_1_1:`pwd`
4.Connect to the new physical standby as the RMAN target to do the following:
restore the standby controlfile,
catalog the standby datafiles and backup pieces,
and switch the standby controlfile to the standby datafile copies
% rman target /
RMAN> startup nomount force;
RMAN> restore standby controlfile from '/home/oracle/u01/0hm30a85_1_1';
RMAN> alter database mount;
RMAN> catalog start with '+DATA/titans_stby';
RMAN> switch database to copy;
RMAN> recover database noredo;
5.Restart managed recovery.
SQL> recover managed standby database using current logfile disconnect;
No comments:
Post a Comment