在Oracleg RAC的安装过程中网络的设置需要谨慎也极其重要
以下将我的Oracleg RAC环境的网络配置列举一下供参考
hosts文件的设置
由于RAC要设置多个地址所以需要准备好网络环境我的hosts文件设置如下
#
# Internet host table
#
localhost
dbrac dbrachurraycomcn loghost
dbracvip dbracviphurraycomcn
dbracpriv dbracprivhurraycomcn
dbrachb dbrachbhurraycomcn
dbrac dbrachurraycomcn
dbracvip dbracviphurraycomcn
dbracpriv dbracprivhurraycomcn
dbrachb dbrachbhurraycomcn
监听器的配置
我的监听器文件配置如下
bash$ cat listenerora
# listeneroradbrac Network Configuration
File: /opt/oracle/product//db/network/admin/listeneroradbrac
# Generated by Oracle configuration tools
LISTENER_DBRAC =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = )(IP = FIRST))
)
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = )(PORT = )(IP = FIRST))
)
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
)
)
)
tnsnamesora文件配置
网络服务名等配置如下
bash$ cat tnsnamesora
# tnsnamesora Network Configuration File: /opt/oracle/product//db/network/admin/tnsnamesora
# Generated by Oracle configuration tools
EYGLE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = eygle)
(INSTANCE_NAME = eygle)
)
)
EYGLE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = eygle)
(INSTANCE_NAME = eygle)
)
)
EYGLE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
(LOAD_BALANCE = yes)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = eygle)
(FAILOVER_MODE =
(TYPE = SELECT)
(METHOD = BASIC)
(RETRIES = )
(DELAY = )
)
)
)
LISTENERS_EYGLE =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
(ADDRESS = (PROTOCOL = TCP)(HOST = dbracvip)(PORT = ))
)
这就是主要的一些配置文件其中Oracle的相关配置文件都是自动生成的VIP可以实现故障时的自动切换