Oracle11g1_uardduplicate physical standby Database Configuration

Source: Internet
Author: User
Oracle11g1_uardduplicate physical standby Database Configuration

Oracle 11g slave uard Duplicate physical standby Database Configuration

Oracle 11g slave uard Duplicate physical standby database configuration (1) physical standby database creation Configuration
# Ver: 1.5 fifth Modification
# Modify: 2013.8.16
# Author: koumm

Read more: Configure Oracle 11g replicuard test and create a Physical Standby Database)

Oracle 11g slave uard physical standby Database Configuration and Active slave uard Test

For more information about DG, see Oracle Data Guard Concepts and Administration.
For details about the parameters for configuring DG, refer to important configuration parameters of Oracle Data Guard.
Configure Oracle 11g Data Guard based on the same host
Note:
This article installs and configures Oracle 11g replicuard to create a physical standby database through duplicate.
Compared with the previous configuration, the following differences exist:
1. the directory structure of the master and slave databases is different.
2. Use duplicate to create a physical standby database.

I. Environment Introduction
1. primary database environment
Operating system version: OEL5.8 x64
Database Version: Oracle 11.2.0.3 x64
Database Name: orcl
Database SID: orcl
Db_unique_name: orcl
Instance_name: orcl
DGMGRL: orcl_DGMGRL

2. Standby database environment
Operating system version: OEL5.8 x64
Database Version: Oracle 11.2.0.3 x64 (only oracle database software is installed, no netca dbca)
Database Name: slave
Database SID: slave
Db_unique_name: slave
Instance_name: slave
DGMGRL: slave_DGMGRL

3. Sequence uard startup sequence
Startup sequence: Start the slave database first and then start the master database
Close sequence: first shut down the master database, then shut down the slave Database

2. Preparations for the primary database environment

1. master database environment comparison
Make full use of the original environment of the primary database, and do not make too many modifications to the parameter configuration of the primary database.
Recreate the password file
# Su-oracle
$ Orapwd file = '/u01/app/oracle/product/11.2.0/db_1/dbs/orapworcl' password = oracle entries = 10 force = y

2. Modify the lisener listening File
Note: add the dgmgrl static listening configuration to lay the foundation for the subsequent dg broker configuration.
$ Cat/u01/app/oracle/product/11.2.0/db_1/network/admin/listener. ora
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.233.200) (PORT = 1521 ))
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521 ))
)
)
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = orcl)
(ORACLE_HOME =/u01/app/oracle/product/11.2.0/db_1)
(SID_NAME = orcl)
)
(SID_DESC =
(GLOBAL_DBNAME = orcl_DGMGRL)
(ORACLE_HOME =/u01/app/oracle/product/11.2.0/db_1)
(SID_NAME = orcl)
)
)
ADR_BASE_LISTENER =/u01/app/oracle
# GLOBAL_DBNAME has a fixed format: _ DGMGRL. .

4. Modify the tnsname. ora File
Note: ORCL is the service name of the master database and DG is the service name of the slave database.
$ Vi/u01/app/oracle/product/11.2.0/db_1/network/admin/tnsnames. ora
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.233.200) (PORT = 1521 ))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
SLAVE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.233.150) (PORT = 1521 ))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = slave)
)
)

5. modify the configuration to the rule file mode.
1) check whether the database is archived
SQL> archive log list;
SQL> shutdown immediate;
SQL> startup mount;
SQL> alter database archivelog;
SQL> alter database flashback on;
SQL> alter database open;

2) set the master database to force logging mode.
SQL> alter database force logging;
SQL> select force_logging, flashback_on from v $ database;
FOR FLASHBACK_ON
---------------------
YES

6. Modify the parameter file of the master database
SQL>
Alter system set instance_name = 'orcl 'scope = spfile;
Alter system set db_unique_name = 'orcl 'scope = spfile;
Alter system set local_listener = 'orcl 'scope = spfile;
Alter system set log_archive_config = 'dg _ CONFIG = (orcl, slave )';
Alter system set log_archive_dest_1 = 'location =/u01/archivelog/valid_for = (all_logfiles, all_roles) db_unique_name = orcl 'scope = spfile;
Alter system set log_archive_dest_2 = 'service = slave lgwr async valid_for = (online_logfiles, primary_role) db_unique_name = slave 'scope = spfile;
Alter system set log_archive_format = 'arch _ % r _ % t _ % s. arc' scope = spfile;
Alter system set fal_client = 'orcl 'scope = spfile;
Alter system set fal_server = 'slave 'scope = spfile;
Alter system set standby_file_management = AUTO;
Alter database add standby logfile group 4'/u01/app/oracle/oradata/orcl/standby_redo04.log 'size 50 M;
Alter database add standby logfile group 5'/u01/app/oracle/oradata/orcl/standby_redo05.log 'size 50 M;
Alter database add standby logfile group 6'/u01/app/oracle/oradata/orcl/standby_redo06.log 'size 50 M;
Alter database add standby logfile group 7'/u01/app/oracle/oradata/orcl/standby_redo07.log 'size 50 M;
SQL> shutdown immediate;
SQL> startup;

Iii. Slave Database Configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.