Oracle 11g Data Guard Configurations by Sajid Hussain
Oracle 11g Data Guard Configurations by Sajid Hussain
Oracle 11g Data Guard Configurations by Sajid Hussain
3
-------------------------------------------------------
Two Machines:
###########################################
###########################################
*.dispathers='(protocol=TCP) (service=primary_DGMGRL)'
DB_UNIQUE_NAME='PRIMARY'
FAL_CLIENT='primary'
FAL_SERVER='standby'
LOG_ARCHIVE_CONFIG='DG_CONFIG=(primary,standby)'
LOG_ARCHIVE_DEST_1='LOCATION=use_db_recovery_file_dest
VALID_FOR=(ALL_LOGFILES,ALL_ROLES)
DB_UNIQUE_NAME=primary'
LOG_ARCHIVE_DEST_2='SERVICE=standby
VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE)
DB_UNIQUE_NAME=standby'
LOG_ARCHIVE_DEST_STATE_1=ENABLE
LOG_ARCHIVE_DEST_STATE_2=ENABLE
service_names='dg1'
STANDBY_FILE_MANAGEMENT='AUTO'
8- Create standby redologs on primary databse with formula {Total Existing +1}.
11- Copy all datafiles,redologs, standby redologs from Primary (Server1} to Standby {Server2} on same location;
SQL> startup;
14.Copy control file to standby database on both location oradata & fast_recovery_area and rename.
Server1:
Server2:
SID: primary
Start listener
Server1:
Server2:
###########################################
###########################################
*.dispatchers='(protocol=TCP) (service=standby_DGMGRL)'
DB_UNIQUE_NAME='STANDBY'
FAL_CLIENT='standby'
FAL_SERVER='primary'
LOG_ARCHIVE_CONFIG='DG_CONFIG=(primary,standby)'
LOG_ARCHIVE_DEST_1='LOCATION=use_db_recovery_file_dest
VALID_FOR=(ALL_LOGFILES,ALL_ROLES)
DB_UNIQUE_NAME=standby'
LOG_ARCHIVE_DEST_2='SERVICE=primary
VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE)
DB_UNIQUE_NAME=primary'
LOG_ARCHIVE_DEST_STATE_1=ENABLE
LOG_ARCHIVE_DEST_STATE_2=ENABLE
service_names='dg1'
STANDBY_FILE_MANAGEMENT='AUTO'
SID: standby
ON Primary.........
hostname: server2.oracle.com
ON Standby.............
hostname: server1.oracle.com
ON Primary……………
ON Standby.......................
SQL> select name,archived,applied from v$archived_log; (Status archive not applied yet)
on Standby:.................
SQl> alter system set LOG_ARCHIVE_DEST_2='SERVICE=primary LGWR AFFIRM ASYNC
VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE)
DB_UNIQUE_NAME=primary';
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE USING CURRENT LOGFILE disconnect;