你好,游客 登录 注册 搜索
背景:
阅读新闻

RedHat 5.4 + ASM + RAW+ Oracle 10g RAC 安装文档

[日期:2011-05-15] 来源:Linux社区  作者:tianlesoftware [字体:大 中 小]

二. 安装Oracle 10gR2 clusterware

 

1. 用Xmanager 软件连上虚拟机之后运行clusterware 的安装软件, Xmanager 支持图形界面, 所以能省很多事。

       主要要先修改/etc/RedHat-release 文件,不然会报错。

              [root@rac2 ~]# more /etc/redhat-release

redhat-4

 

2. 确认你的安装目录是/u01/app/oracle/product/crs

 

3. 增加相关结点信息

rac1 rac1-priv rac1-vip

rac2 rac2-priv rac2-vip

 

4.指定 eth0 的类型时public

 

5. 指定OCR 和 Voting Disk

一般而言,如果采用存储来存放OCR和Voting Disk. 存储本身就提供了redundancy策略,此时我们可以选择External Redundancy 选项, 此时Oracle 就不在考虑软件冗余了。 如果没有使用存储设备或者存储为RAID0,那么就可以使用Oracle 自己提供的软件冗余机制 Normal Redundancy 选项,此时就会激活Mirror Location 选项. 用来指定镜像文件位置, Oracle 的Clusterware在运行时会维护这个Mirror文件的内容同步。

 

 

OCR 最多只有一份冗余:

/dev/raw/raw1

/dev/raw/raw2

 

Voting Disk 最多可以定义2份冗余:

/dev/raw/raw3

/dev/raw/raw4

/dev/raw/raw5

 

6. 开始安装了,结束时会提示用root在每个节点上运行orainstRoot.Sh 和 root.Sh脚本, 在第二个结点上运行root.Sh 后自动调用vipca 这个命令, 在第二个结点运行root.Sh 之前要修改一下vipca命令, 不然可能会报错。

 

RAC安装时需要执行4个脚本及意义

http://www.linuxidc.com/Linux/2011-05/36000.htm

 

注意: VIPCA 命令也是用ROOT 用户来运行的, 只需要在一个结点运行就可以了。

 

 

进入$CRS_HOME/bin/目录, 用vi来修改vipca 和 srvctl 2个命令。

 

问题1: vipca报错,是redhat的bug

Running vipca(silent) for configuring nodeapps

/home/oracle/crs/oracle/product/10/crs/jdk/jre//bin/java: error while loading

shared libraries: libpthread.so.0: cannot open shared object file:

No such file or directory

 

解决方法:

Remember to re-edit these files on all nodes:

<CRS_HOME>/bin/vipca

<CRS_HOME>/bin/srvctl

<RDBMS_HOME>/bin/srvctl

<ASM_HOME>/bin/srvctl

 

after applying the 10.2.0.2 or 10.2.0.3 patchsets, as these patchset will still include those settings unnecessary for OEL5 or RHEL5 or SLES10.  This issue was raised with development and is fixed in the 10.2.0.4 patchsets.

 

Note that we are explicitly unsetting LD_ASSUME_KERNEL and not merely commenting out its setting to handle a case where the user has it set in their environment (login shell).

 

$ vi vipca

... ...

Linux) LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:$ORACLE_HOME/srvm/lib:$LD_LIBRARY_PATH

       export LD_LIBRARY_PATH

        echo $LD_LIBRARY_PATH

        echo $CLASSPATH

       #Remove this workaround when the bug 3937317 is fixed

       arch=`uname -m`

       if [ "$arch" = "i686" -o "$arch" = "ia64" ]

       then

        # LD_ASSUME_KERNEL=2.4.19   

        # export LD_ASSUME_KERNEL 

        echo  -- 这里一定要加上,不然返回会报错

       fi

       #End workaround

 

问题2: 如果遇到这个错误:

# vipca

Error 0(Native: listNetInterfaces:[3])

[Error 0(Native: listNetInterfaces:[3])]

解决方法:

在CRS_HOME下 运行 oifcfg 命令:

 

# ./oifcfg setif -global eth0/10.85.10.0:public

# ./oifcfg setif -global eth1/192.168.1.0:cluster_interconnect

# ./oifcfg getif

eth0 10.85.10.0 global public

eth1 192.168.1.0 global cluster_interconnect

 

-- 注意这里最后一个是0. 代表一个网段。 在一个节点设置之后,其他节点也能看到。  

 

然后在手工运行vipca添加nodeapps resource即可。

 

问题3:An unexpected exception has been detected in native code outside the VM.

Unexpected Signal : 11 occurred at PC=0xB7503E29

Function=__libc_free+0x49

Library=/lib/tls/libc.so.6

 

修改主机名不正确导致的。

RHEL

/etc/sysconfig/network 主机名,如果在/etc/hosts中解析不了。就报这个错误!

 

7.  clusterware 就安装结束.

 

确认一下.

$ /u01/app/oracle/product/crs/bin/olsnodes -n

rac1

rac2

$ ls -l /etc/init.d/init.*

-r-xr-xr-x 1 root root 1951 Oct 4 14:21 /etc/init.d/init.crs*

-r-xr-xr-x 1 root root 4714 Oct 4 14:21 /etc/init.d/init.crsd*

-r-xr-xr-x 1 root root 35394 Oct 4 14:21 /etc/init.d/init.cssd*

-r-xr-xr-x 1 root root 3190 Oct 4 14:21 /etc/init.d/init.evmd*

 

检查CRS 安装启动情况:用Root用户执行:

$CRS_HOME/bin/crsctl check crs

CSS appears healthy

CRS appears healthy

EVM appears healthy

 

表明CRS 安装完成,并且启动成功

[root@rac1 bin]# ./crs_stat -t -v

Name           Type           R/RA   F/FT   Target    State     Host

----------------------------------------------------------------------

ora.rac1.gsd   application    0/5    0/0    ONLINE    ONLINE    rac1

ora.rac1.ons   application    0/3    0/0    ONLINE    ONLINE    rac1

ora.rac1.vip   application    0/0    0/0    ONLINE    ONLINE    rac1

ora.rac2.gsd   application    0/5    0/0    ONLINE    ONLINE    rac2

ora.rac2.ons   application    0/3    0/0    ONLINE    ONLINE    rac2

ora.rac2.vip   application    0/0    0/0    ONLINE    ONLINE    rac2

 

注:如果clusterware 安装失败,再次运行安装程序,里面可以把之前的安装删除掉,删除之后在进行安装。

linux
相关资讯       Oracle教程 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款