Step by Step Guide On Creating Physical Standby Using RMAN Backup Based Duplicate in ASM For ASM Primary (Doc ID 837102.1)
Step by Step Guide On Creating Physical Standby Using RMAN Backup Based Duplicate in ASM For ASM Primary (Doc ID 837102.1)
Step By Step Guide On Creating Physical Standby Using RMAN Backup based Duplicate In ASM For ASM Primary (Doc ID
837102.1)
In this Document
Goal
Solution
APPLIES TO:
GOAL
This document offers step by step procedure to create ASM physical standby from ASM primary.
SOLUTION
NOTE: In the images and/or the document content below, the user information and environment data used represents fictitious data from the
Oracle sample schema(s), Public Documentation delivered with an Oracle database product or other training material. Any similarity to actual
environments, actual persons, living or dead, is purely coincidental and not intended in any manner.
1 of 6 02/02/23, 3:54 pm
Document 837102.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=1cjxojvrfs_285&id...
For the purposes of this document, the following fictitious environment is used as an example to describe the procedure:
Primary Database:
DB_NAME: PRIM (net service name 'PRIM')
Standby Database:
DB_UNIQUE_NAME: STBY (net service name 'STBY')
Pre-Requisite
a) Database (PRIMARY) is up and running and the datafiles, controlfiles residing in ASM.
b) ASM instance and diskgroups configured in STANDBY server.
c) Network connectivity between PRIMARY and STANDBY server
PROCEDURE
2 of 6 02/02/23, 3:54 pm
Document 837102.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=1cjxojvrfs_285&id...
b. Create SRL
ALTER DATABASE ADD STANDBY LOGFILE GROUP 4 SIZE 100M;
NOTE: The SRL will be created in the ASM Disk group mentioned in init.ora parameter DB_CREATE_ONLINE_LOG_DEST_1
c. Verify the standby redo log file groups were created(do this after the creation of standby database)
DB_NAME=PRIM
DB_UNIQUE_NAME=PRIM
LOG_ARCHIVE_CONFIG='DG_CONFIG=(PRIM,STBY)'
LOG_ARCHIVE_DEST_2= 'SERVICE=STBY LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=STBY'
LOG_ARCHIVE_DEST_STATE_2=DEFER
REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE
LOG_ARCHIVE_FORMAT=%t_%s_%r.arc
LOG_ARCHIVE_MAX_PROCESSES=30
FAL_SERVER=STBY
FAL_CLIENT=PRIM
DB_FILE_NAME_CONVERT='STBY','PRIM'
LOG_FILE_NAME_CONVERT='STBY','PRIM'
STANDBY_FILE_MANAGEMENT=AUTO
DB_NAME=PRIM
DB_UNIQUE_NAME=STBY
LOG_ARCHIVE_CONFIG='DG_CONFIG=(PRIM,STBY)'
CONTROL_FILES='+DATA','+FRA'
3 of 6 02/02/23, 3:54 pm
Document 837102.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=1cjxojvrfs_285&id...
DB_FILE_NAME_CONVERT='PRIM','STBY'
LOG_FILE_NAME_CONVERT='PRIM','STBY'
LOG_ARCHIVE_FORMAT=log%t_%s_%r.arc
LOG_ARCHIVE_DEST_2= 'SERVICE=PRIM LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=PRIM'
LOG_ARCHIVE_DEST_STATE_1=ENABLE
LOG_ARCHIVE_DEST_STATE_2=ENABLE
REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE
STANDBY_FILE_MANAGEMENT=AUTO
FAL_SERVER=PRIM
FAL_CLIENT=STBY
Note: If the ASM Disk groups names are different between PRIMARY and STANDBY do the necessary changes in STANDBY with the parameters
DB_CREATE_FILE_DEST and DB_CREATE_ONLINE_LOG_DEST_n
a) Copy the RMAN backup files created in /tmp/dbbkp (step3) to STANDBY in identical location
Example:
scp /tmp/prim/* oracle@<host>:/tmp/stby/*
In PRIMARY (TNSNAMES.ORA)
STBY=
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = <name>)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = STBY.<server>)
)
)
In STANDBY (TNSNAMES.ORA)
PRIM=
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = <name>)(PORT = 1521))
4 of 6 02/02/23, 3:54 pm
Document 837102.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=1cjxojvrfs_285&id...
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = PRIM.<server>)
)
)
NOTE: Use TNSPING <servicename> to check the connectivity between PRIMARY and STANDBY
8. Start the STANDBY instance and use RMAN duplicate to create standby database
NOTE: The following RMAN duplicate connects to target, catalog and auxiliary. Not all these connections are mandatory. For example, if the backup is
contained within target controlfile, a catalog connection is not necessary. In 11g release 2 and higher, RMAN duplicate supports running duplicate without a
target connection. Auxiliary only connection is possible with disk backups. See appropriate RMAN documentation for details.
For Example,
In PRIMARY
5 of 6 02/02/23, 3:54 pm
Document 837102.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.ctrl-state=1cjxojvrfs_285&id...
In STANDBY
11. Verify whether the log are shipped and applied properly in the standby
d. Verify the new redo data was archived on the standby database.On the standby database, query the V$ARCHIVED_LOG view to verify the redo data was received
and archived on the standby database:
NOTE: Verify new archived redo log files were applied. At the standby database, query the V$ARCHIVED_LOG view to verify the archived redo log files were applied.
6 of 6 02/02/23, 3:54 pm