在oracle11g中配置多个DataGuard物理备机
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了在oracle11g中配置多个DataGuard物理备机相关的知识,希望对你有一定的参考价值。
主机配置
alter system set DB_UNIQUE_NAME=‘starboss‘ scope=spfile; alter system set LOG_ARCHIVE_CONFIG=‘DG_CONFIG=(starboss,starbossstby01,starbossstby02)‘; alter system set LOG_ARCHIVE_DEST_1=‘LOCATION=/opt/app/oracle/archivelog/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=starboss‘;
alter system set LOG_ARCHIVE_DEST_2=‘SERVICE=starbossstby01 LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=starbossstby01‘; alter system set LOG_ARCHIVE_DEST_3=‘SERVICE=starbossstby02 LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=starbossstby02‘;
alter system set LOG_ARCHIVE_DEST_STATE_1=‘ENABLE‘; alter system set LOG_ARCHIVE_DEST_STATE_2=‘ENABLE‘; alter system set LOG_ARCHIVE_DEST_STATE_3=‘ENABLE‘; alter system set LOG_ARCHIVE_FORMAT=‘%t_%s_%r.arc‘ scope=spfile; alter system set REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE scope=spfile; alter system set LOG_ARCHIVE_MAX_PROCESSES=30;
备机01配置
alter system set DB_UNIQUE_NAME=‘starbossstby01‘ scope=spfile; alter system set LOG_ARCHIVE_CONFIG=‘DG_CONFIG=(starbossstby01,starboss)‘; alter system set LOG_ARCHIVE_DEST_1=‘LOCATION=/opt/app/oracle/archivelog/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=starbossstby01‘; alter system set LOG_ARCHIVE_DEST_2=‘SERVICE=starboss LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=starboss‘; alter system set LOG_ARCHIVE_DEST_STATE_1=‘ENABLE‘; alter system set LOG_ARCHIVE_DEST_STATE_2=‘ENABLE‘; alter system set LOG_ARCHIVE_FORMAT=‘%t_%s_%r.arc‘ scope=spfile; alter system set REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE scope=spfile; alter system set FAL_SERVER=‘starboss‘; alter system set FAL_CLIENT=‘starbossstby01‘; alter system set STANDBY_FILE_MANAGEMENT=‘AUTO‘; alter system set LOG_FILE_NAME_CONVERT=‘/stardb_log1/starboss‘,‘/stardb_log1/starboss‘ alter system set DB_FILE_NAME_CONVERT=‘/opt/ora10/oradata/starboss/‘,‘/opt/ora10/oradata/starboss/‘
备机02配置
alter system set DB_UNIQUE_NAME=‘starbossstby02‘ scope=spfile; alter system set LOG_ARCHIVE_CONFIG=‘DG_CONFIG=(starbossstby02,starboss)‘; alter system set LOG_ARCHIVE_DEST_1=‘LOCATION=/opt/app/oracle/archivelog/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=starbossstby02‘; alter system set LOG_ARCHIVE_DEST_2=‘SERVICE=starboss LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=starboss‘; alter system set LOG_ARCHIVE_DEST_STATE_1=‘ENABLE‘; alter system set LOG_ARCHIVE_DEST_STATE_2=‘ENABLE‘; alter system set LOG_ARCHIVE_FORMAT=‘%t_%s_%r.arc‘ scope=spfile; alter system set REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE scope=spfile; alter system set FAL_SERVER=‘starboss‘; alter system set FAL_CLIENT=‘starbossstby02‘; alter system set STANDBY_FILE_MANAGEMENT=‘AUTO‘; alter system set LOG_FILE_NAME_CONVERT=‘/stardb_log1/starboss‘,‘/stardb_log1/starboss‘ alter system set DB_FILE_NAME_CONVERT=‘/opt/ora10/oradata/starboss/‘,‘/opt/ora10/oradata/starboss/‘
以上是关于在oracle11g中配置多个DataGuard物理备机的主要内容,如果未能解决你的问题,请参考以下文章
Oracle数据库11g 中Data Guard物理备用数据库搭建与配置
Oracle 11g Dataguard 配置,维护与详解 (ADG)