Oracle 11g +CentOS6 RAC集群搭建
官方文档参考:
https://oracle-base.com/articles/11g/oracle-db-11gr2-rac-installation-on-oel5-using-virtualbox#create_shared_disks 网友文档参考:
http://blog.itpub.net/28883355/viewspace-1125122/ 本文档linux采用centos6.7
虚拟机采用vmware workstation10 本地网络环境:10.16.122.N
本地主机ip地址:10.16.122.70 /etc/hosts配置: #public ip
10.16.122.197 rac01 10.16.122.199 rac02 #virtual ip
10.16.122.210 rac01-vip 10.16.122.220 rac02-vip #private ip
192.168.10.1 rac01-priv 192.168.10.2 rac02-priv #scan ip
10.16.122.230 rac-scan 10.16.122.231 rac-scan 10.16.122.232 rac-scan
注:SCAN ip必须与public ip和VIP在一个子网。 安装虚拟机(略): 注意:网络链接选择桥接 安装两台虚拟机略 配置网络:
虚拟机rac01
# vim /etc/sysconfig/network-scripts/ifcfg-eth0 内容如下:
DEVICE=eth0 TYPE=Ethernet
UUID=c51253ff-4b8f-4e1a-935b-0ea4d352e870
ONBOOT=yes
NM_CONTROLLED=yes BOOTPROTO=none
IPADDR=10.16.122.197//共有地址,即IP配置中的rac01 PREFIX=24 DEFROUTE=yes
IPV4_FAILURE_FATAL=yes IPV6INIT=no
NAME=\
HWADDR=00:0c:29:85:ca:61//mac地址 NETMASK=255.255.255.0//子网掩码 GATEWAY=10.16.122.254 USERCTL=no
虚拟机rac02 DEVICE=eth0 TYPE=Ethernet
UUID=c51253ff-4b8f-4e1a-935b-0ea4d352e870 ONBOOT=yes
NM_CONTROLLED=yes BOOTPROTO=none
IPADDR=10.16.122.199//共有地址,即IP配置中的rac02 PREFIX=24 DEFROUTE=yes
IPV4_FAILURE_FATAL=yes IPV6INIT=no
NAME=\
HWADDR=00:0c:29:36:cf:09 NETMASK=255.255.255.0 GATEWAY=10.16.122.254 USERCTL=no
配置完成后:重启网络 #service network restart
测试本地主机window ip与虚拟机能否ping通 # ping 10.16.122.70 添加网卡
关闭虚拟机,右击虚拟机—设置—添加—网络适配器
选择仅主机模式(only host ) 配置新添加的网卡
启动虚拟机,执行#ifconfig, 查看是否多出一块网卡(eth1新增),如下:
eth0 Link encap:Ethernet HWaddr 00:0C:29:85:CA:61 inet addr:10.16.122.199 Bcast:10.16.122.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe85:ca61/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:8033 errors:0 dropped:0 overruns:0 frame:0 TX packets:652 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000
RX bytes:875509 (854.9 KiB) TX bytes:95661 (93.4 KiB)
eth1 Link encap:Ethernet HWaddr 00:0C:29:85:CA:6B inet addr:192.168.10.1 Bcast:192.168.10.255