快速业务通道

rac-single data guard

作者 佚名技术 来源 Linux系统 浏览 发布时间 2012-03-25

一、环境
操作系统: Red Hat Enterprise Linux Server release 5 (Tikanga)
Primary数据库(rac):
IP地址:172.168.1.206 172.168.1.208
vip地址:172.168.1.116 172.168.1.118
数据库SID:syk1 syk2
DB_NAME:syk
数据、控制、日志文件放在 ASM

Standby数据库(单机):
IP地址:172.168.1.222
数据库SID:syk
DB_NAME:syk
数据、控制、日志文件使用文件系统 /oradata

二、tnsnames.ora在rac和standby相同
SYK2 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = syk)
(INSTANCE_NAME = syk2)
)
)

SYK1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = syk)
(INSTANCE_NAME = syk1)
)
)

SYK =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip)(PORT = 1521))
(LOAD_BALANCE = yes)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = syk)
)
)

SYK_SINGLE =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 172.168.1.222)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = syk)
)
)

LISTENERS_SYK =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = rac2-vip)(PORT = 1521))
)

EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)

standby上的listener.ora
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = syk)
(ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1)
(SID_NAME = syk)
)
)

LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 172.168.1.222)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
)
)

三、修改参数(在rac1上如下操作)

SQL> create pfile=''/home/oracle/pfilesyk.ora'' from spfile;
添加如下参数
*.db_unique_name=''SYK''
*.service_names=''syk_rac''
*.log_archive_config=''dg_config=(syk,syk_single)''
*.log_archive_dest_1=''LOCATION=/home/oracle/archive/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES)'' DB_UNIQUE_NAME=''syk''
*.log_archive_dest_2=''service=syk_single LGWR valid_for=(online_logfiles,primary_role) db_unique_name=syk_single''
*.log_archive_dest_state_1=''ENABLE''
*.log_archive_dest_state_2=''ENABLE''
*.db_file_name_convert=''/oradata/syk'','' ASM_DATA/syk/datafile'',''/oradata/syk'','' ASM_DATA/syk/tempfile''
*.log_file_name_convert=''/oradata/syk'','' ASM_DATA/syk/onlinelog'',''/oradata/syk'','' ASM_RECOVER/syk/onlinelog''
syk1.fal_client=''syk1''
syk2.fal_client=''syk2''
*.fal_server=''syk_single''
*.standby_file_management=''auto''
*.STANDBY_ARCHIVE_D

凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢!

分享到: 更多

Copyright ©1999-2011 厦门凌众科技有限公司 厦门优通互联科技开发有限公司 All rights reserved

地址(ADD):厦门软件园二期望海路63号701E(东南融通旁) 邮编(ZIP):361008

电话:0592-5908028 传真:0592-5908039 咨询信箱:web@lingzhong.cn 咨询OICQ:173723134

《中华人民共和国增值电信业务经营许可证》闽B2-20100024  ICP备案:闽ICP备05037997号