Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1925846
  • 博文数量: 389
  • 博客积分: 7877
  • 博客等级: 少将
  • 技术积分: 4521
  • 用 户 组: 普通用户
  • 注册时间: 2007-12-10 14:02
文章分类

全部博文(389)

文章存档

2024年(1)

2022年(1)

2021年(1)

2020年(1)

2019年(1)

2018年(3)

2017年(6)

2016年(4)

2015年(8)

2014年(15)

2013年(31)

2012年(19)

2011年(47)

2010年(33)

2009年(105)

2008年(109)

2007年(4)

分类: Oracle

2011-12-12 01:45:28

RAC环境中的tnsnames.ora配置文件:

# tnsnames.ora Network Configuration File: /opt/app/oracle/product/10.2.0/db_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

CRMDB2 =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb2_vip)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = crmdb)
      (INSTANCE_NAME = crmdb2)
    )
  )

CRMDB1 =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb1_vip)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = crmdb)
      (INSTANCE_NAME = crmdb1)
    )
  )


CRMDB =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb1_vip)(PORT = 1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb2_vip)(PORT = 1521))
    (LOAD_BALANCE = yes)
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = crmdb)
    )
  )

LISTENERS_CRMDB =
  (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb1_vip)(PORT = 1521))
    (ADDRESS = (PROTOCOL = TCP)(HOST = testdb2_vip)(PORT = 1521))
  )



======================================================


RAC环境中的listener.ora配置文件:

# listener.ora.crmdb1 Network Configuration File: /opt/app/oracle/product/10.2.0/db_1/network/admin/listener.ora.crmdb1
# Generated by Oracle configuration tools.

LISTENER_CRMDB1 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = testdb1_vip)(PORT = 1521)(IP = FIRST))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.1.6)(PORT = 1521)(IP = FIRST))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )


======================================================

连接RAC数据库的客户端tnsnames.ora配置文件:

# tnsnames.ora Network Configuration File: /u01/app/oracle/oracle/product/10.2.0/db_1/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

CRMDB =
  (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.1.7)(PORT = 1521))
    (CONNECT_DATA =
      (SERVICE_NAME = crmdb)
       (FAILOVER_MODE =
        (TYPE = SELECT)
        (METHOD = BASIC)
        (RETRIES = 180)
        (DELAY = 5)
       )

    )
  )


======================================================

RAC环境中的local_listener和remote_listener的值:
SQL*Plus: Release 10.2.0.5.0 - Production on Mon Dec 12 01:48:46 2011

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options

SQL> show parameter list

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
local_listener                       string      LISTENERS_CRMDB
remote_listener                      string      LISTENERS_CRMDB

阅读(2345) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~