如果要使用GNS,必须配置DNS,让GNS的VIP可以被DNS解析,并且,可以分发下级域名给GNS进行解析。
结果测试,可以修改nslookup,避免繁琐的DNS配置工作。
Normal
0
7.8 磅
0
2
false
false
false
EN-US
ZH-CN
X-NONE修改nslookup
[root@database1 ~]# mv
/usr/bin/nslookup /usr/bin/nslookup.org
[root@database1 ~]# vi
/usr/bin/nslookup
#!/bin/sh
HOSTNAME=${1}
if [[ $HOSTNAME =
"gns.grid.zhangqiaoc.com" ]]; then
echo "Server:83.16.16.254"
echo "Address:83.16.16.254#53"
echo ""
echo "Name:gns.grid.zhangqiaoc.com"
echo "Address: 83.16.16.30"
echo ""
elif [[ $HOSTNAME =
"83.16.16.30" ]]; then
echo "Server:83.16.16.254"
echo "Address:83.16.16.254#53"
echo ""
echo "30.16.16.83.in-addr.arpaname = gns.grid.zhangqiaoc.com."
echo ""
else
/usr/bin/nslookup.org $HOSTNAME
fi
[root@database1 ~]# chmod 755
/usr/bin/nslookup
[root@database2 ~]# nslookup
gns.grid.zhangqiaoc.com
Server:83.16.16.254
Address:83.16.16.254#53
Name:gns.grid.zhangqiaoc.com
Address: 83.16.16.30
其中,83.16.16.254为虚构的DNS地址,gns.grid.zhangqiaoc.com为GNS的名称,83.16.16.30为GNSVIP
另外,由于启用了GNS,VIP/SCANVIP地址是通过DHCP获取的,但是很奇怪,VMWARE自带的DHCP功能无法给VIP/SCANVIP分配地址。必须另外配置个虚拟机做DHCP服务器,这个虚拟机只需要128M内存就够了。
配置DNS地址:/etc/resolv.conf中配置为GNS VIP地址83.16.16.30。通过修改nslookup,可以避免到时候地址的解析问题。
在Grid安装中,在第4步:Setting up Grid Infrastructure中:
Cluster Name:rac
SCAN Name:rac-scan.grid.zhangqiaoc.com
SCAN Port:1521
GNS Sub Domain:grid.zhangqiaoc.com
GNS VIP Address:83.16.16.30
安装正常完成,所有资源正常,其他功能正在测试