Steps to create and Flashback database of RAC Database(11.2.0.4) on Datagurad Enviroment.
>> Formating
SQL>set linesize 121
SQL>col name format a15
SQL>col time format a32
--==========Restore Point============
>>Create Restore Point
SELECT name, scn, time FROM gv$restore_point;
create restore point bm_20150723 guarantee flashback database;
create restore point asd_20150723 guarantee flashback database;
create restore point afd_20150723 guarantee flashback database;
>>Drop Restore Point
SELECT name, scn, time FROM gv$restore_point;
DROP RESTORE POINT bm_20150723;
DROP RESTORE POINT asd_20150723;
DROP RESTORE POINT afd_20150723;
--=======Flashback DB======
>> On Primary DB
Node-1: 172.31.xxx.x, Node-2: 172.31.xxx.x
On Primary DB Steps are:
1. Shutdown database [Node-1 & Node-2].
2. Open database in Mount Mode[Node-1].
3. Flashback database to specific restore point[Node-1].
4. Database Open in Read Only Mode[For Checking Purpose].
5. Shutdown database[Node-1].
6. Database Open in Mount Mode[Node-1].
4. Finally Database open in RESET LOGS.
SQL Command:
SQL> shutdown immediate; [Node-1]
SQL> shutdown immediate; [Node-2]
SQL> startup mount [Node-1]
SQL> flashback database to restore point AGL_20150723;[Node-1]
SQL>alter database open read only;[Node-1]
SQL>shutdown immediate; [Node-1]
SQL>startup mount [Node-1]
SQL> alter database open resetlogs; [Node-1]
Note: After database open from Primary[Node-1] then below from command run from Primary[Node-2].
SQL>startup [Node-2]
>> On Standby DB
On Standby DB Steps are:
1. Shutdown database.
2. Open database in Mount Mode.
3. Flashback database to SCN. [SCN must be smaller than PRIMARY DB flashback SCN ]
6. Database Open in read only mode.
4. Recover database with real time apply.
SQL> startup mount
SQL> flashback database to scn 3462606000;
SQL> alter database open read only;
SQL> alter database recover managed standby database using current logfile disconnect from session;
>> Formating
SQL>set linesize 121
SQL>col name format a15
SQL>col time format a32
--==========Restore Point============
>>Create Restore Point
SELECT name, scn, time FROM gv$restore_point;
create restore point bm_20150723 guarantee flashback database;
create restore point asd_20150723 guarantee flashback database;
create restore point afd_20150723 guarantee flashback database;
>>Drop Restore Point
SELECT name, scn, time FROM gv$restore_point;
DROP RESTORE POINT bm_20150723;
DROP RESTORE POINT asd_20150723;
DROP RESTORE POINT afd_20150723;
--=======Flashback DB======
>> On Primary DB
Node-1: 172.31.xxx.x, Node-2: 172.31.xxx.x
On Primary DB Steps are:
1. Shutdown database [Node-1 & Node-2].
2. Open database in Mount Mode[Node-1].
3. Flashback database to specific restore point[Node-1].
4. Database Open in Read Only Mode[For Checking Purpose].
5. Shutdown database[Node-1].
6. Database Open in Mount Mode[Node-1].
4. Finally Database open in RESET LOGS.
SQL Command:
SQL> shutdown immediate; [Node-1]
SQL> shutdown immediate; [Node-2]
SQL> startup mount [Node-1]
SQL> flashback database to restore point AGL_20150723;[Node-1]
SQL>alter database open read only;[Node-1]
SQL>shutdown immediate; [Node-1]
SQL>startup mount [Node-1]
SQL> alter database open resetlogs; [Node-1]
Note: After database open from Primary[Node-1] then below from command run from Primary[Node-2].
SQL>startup [Node-2]
>> On Standby DB
On Standby DB Steps are:
1. Shutdown database.
2. Open database in Mount Mode.
3. Flashback database to SCN. [SCN must be smaller than PRIMARY DB flashback SCN ]
6. Database Open in read only mode.
4. Recover database with real time apply.
SQL Command:
SQL> shutdown immediateSQL> startup mount
SQL> flashback database to scn 3462606000;
SQL> alter database open read only;
SQL> alter database recover managed standby database using current logfile disconnect from session;
No comments:
Post a Comment