《ORACLE11GR2在REDHAT63环境中搭建RAC集群及简单维护.docx》由会员分享,可在线阅读,更多相关《ORACLE11GR2在REDHAT63环境中搭建RAC集群及简单维护.docx(54页珍藏版)》请在优知文库上搜索。
1、1、系统环境.,硬件环境效劳器:vmware10,新建2个虚拟机主机名分别为rac1.和rac2,每个虚拟机分配IoG磁盘空间,添加两个网络适配器。其中第二个适配器网络连接调整为自定义,且两个节点保持一致。0命懈内存2Ge己隹膜(C)ftIia11国加抬枚“毋(SCSD40GB月崎在揍nae三幅横通(自动)Ctsrt(6):1.S1.5ftt!ttfRI(1K32自定义(VMnMO)1.5WSFM5H*(P)$加O*(t):用于共“王幽IP胞地一加限存在C仅主Mf1.1.Jt(三):与王机垃*的专用庠B三自玳*自定义但):力蜜。网络VXnCO1.ANEtt(1.):UME8(5).*V).Wi
2、donws本机ip:192.168.6.11.2、 软件环境数据库:Orac1.e1.1.2.0.4database-86-64GRID:Orac1.e1.1.2.0.,1.grid-X86-64掾作系统:rhe1.-server_6.3-x8664采用最小化安装1.3、 网络环境【P地址规划分配为IP名称子网掩码IP地址RaCI-PUb1.iC255.255.255.0192.168.6.11fcc2-pub1.ic255.255.255.0192.168.6.12Rac!-private255.255.255.02.2.2.2Rac2-private255.255.255.02.2.2.3
3、Rac1.rip255.255.255.0192.168.6.13Rac2-vip255.255.255.0192.168.6.14SCAN255.255.255.0192.168.6.151.4、 共享磁盘分区方案创立四个共享鹿盘sdb、sdc.sdd.sde,每个磁盘方案分三个分区sdasda2sdb1.sdb3sdc1.sdc3sdd1.sdd3sde1.sde3sda1.sdbsdb2sdcsdc2sddsdd2Sdesde22、前期环境准备2.1 配置静态IP地址Vitcsysconfig/network-scripts/ifcfg-th修改ip地址.每个虚拟机eth网卡为PUb1.
4、ic,DEVICE=thO,BOOTPROTO=eStatic,HIADDR=wOO:0C:29:D1.:4E:A6Ji1.C(OTRo1.1.ED=yesONBOOT=yesTYPE=EthernetUUID=59cb6a0-deb0-4164-a2b0-8b4dcc0cb027IPADDR=192.168.6.11NETMASK=255.255.255.0GATEIAY=192.168.6.1vi/etc/sysconfignet三ork-scriptsifcfg-th1.修改ip地址.每个虚拟机eth1.网卡位privateDEVICE=eth1.BOOTPROTO=eStaticHIA
5、DDR=eOO:OC:29:DI:4E:A6ri,cmxiED=,ys,ONBOOT=yesTYPE=eEthernet*UUID=,e59cb6a0-deb0-4164-a2b0-8b4dcc0cb027IPADDR=2.2.2.2NETMASK=255.255.255.0修致完成后执行servicenetworkrestart2.2 在rac1.和rac2上分别关闭防火墙serviceiptab1.esstop一停止防火墙chkconfigiptab1.esoff一兼用防火墙2.3 3在rac1.和rac2上分别修改主机名vi/etc/sysconfig/network重启生效,一个rac
6、1.,另一个rac2HOSTNAME=rac1.2.4在rac1.和rac2上分别改hostsvitchosts添加对应的ip信息#pub1.ic192.168.6.180rac1.192.168.6.181rac2eprivate2.2.2.1rac1.-priv2.2.2.2rac2-privvirtua1.192.168.6.182rac1.-vip192.168.6.183rac2-vip#SCan192.168.6.184c1.uster-scan2.5在rac1.和rac2上分别执行配置内核参数vietcsysct1.conf参加以下内容fs.aio-na-nr=1048576s.
7、=6815744kerne1.,shma11kerne1.,shmmaxkerne1.,sh11unni=2147483648=68719476736=4096kerne1.,sem=25032000100128net.ipv1.ip1.oca1.portrange-900065500net.core.rmem_defau1.t=262144net.core.rmem_max=4191304net.core,umem.defau1.t=262144net.core,umemmax=1048586使修改参数立即生效:sysct1.-p2.6在rac1.和rac2上分别执行修改1.imitsvie
8、tcsecurity1.i三its.conf参加以下信息gridsoftnproc2047gridhardnproc16384gridsoftnogridhafs1.efau11s,size=1024aOOount-oremountdvsh三2.12 在rac1.和rac2上分别检查软件是否全部安装rpo-qaIgrepbinuti1.s-rpn-qagrepCoepatTibstdc+-rpn-qagrepe1.futi1.s-1.ibe1.f-rpin-qagrepe1.futi1.s-1.ibe1.f-deve1.-rp-qagrepg1.ibcFPD-qaIgrepg1.ibc-co三
9、non-rpn-qaIgrepg1.ibc-deve1.-rpn-qagrepgcc-rpm-qagrepgcc-c+-rpo-qaIgrepIibaio-rpn-qagrep1.ibaio-dve1.-rpn-qagrepIibgcc-rpoi-qagrepIibstdc+-rpm-qagrepIibStdC+-(Ieve1.-rpm-qagrepDake-rpn-qagrepsysstat-rpn-qagrepUniXOMC-rpn-qagrepunixODBC-deve1.-2.13 在rac1.和rac22分别将未安装的包通过yum安装kdiryu三ountdvcdronyu三viet
10、cyu.repos,dche11bin.repo添加以下内容rhe1.-chenbinname=RedHatEnterprise1.inuxSre1.easever-Sbasearch-Debugbaseur1.=enab1.ed=1.gpgcheck=1.gpgkey=RPM-GPG-KEY-redhat-re1easeyum1.ist一杳牙可用包yun-yinsta1.1.binuti1.sCOaPat-e1.futi1.s-1.ibe1.fgccgcc-kerne1.-*ksh-1.ibaio-Iibgcc-*IibgOi-*Iibstdc+-*make-*nu三act1.-dev1.-
11、sysstat-unixODBC-pdksh2.14 在Oradb1.和rac2上分别关闭不需要的效劳chkconfigautofsoffchkconfigacpidoffchkconfigsendaai1.offchkconfigcups-config-daenonoffchkconfigcpusoffchknfigxfsoffchkconfigI1.SenSOrSoffchkconfiggpooffchkconfigOpenibdoffchknfigpcmciaoffchkconfigcpuspeedoffchkconfignfs1.ockoffchkconfigip6tab1.esoff
12、chknfigrpcidmioffchkconfigapmdoffchkconfigsendaai1.offchkconfigarptab1.es_JfoffchkconifgB1.crocode-ct1.offchknfigrpcgssdoffchkconfigntpdoff3、添加组和用户3.1在rac1.和rac2上分别添加OraC1.e和grid用户和组groupadd-g501Oinsta1.1.groupadd-g502dbagroupadd-g503oprgroupadd-g504asoadningroupadd-g505asaopergroupadd-g506asmdbauseradd-goinsta1.1.-Gdba,asadba.operorac1