Centos 5.8, kernel为:
uname -r
2.6.18-308.el5
安装ASM三个包:
rpm -ivh oracleasm-support-2.1.1-1.el4.i386.rpm
rpm -ivh oracleasm-2.6.18-128.el5-2.0.5-1.el5.i686.rpm
rpm -ivh oracleasmlib-2.0.4-1.el5.i386.rpm
这三个包可以在下载到。
安装完成之后,进行配置
[root@digdeep oracle]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting without typing an
answer will keep that current value. Ctrl-C will abort.
Default user to own the driver interface [oracle]:
Default group to own the driver interface [dba]:
Start Oracle ASM library driver on boot (y/n) [y]:
Scan for Oracle ASM disks on boot (y/n) [y]:
Writing Oracle ASM library driver configuration: done
Initializing the Oracle ASMLib driver: [FAILED]
[root@digdeep oracle]#
发生了错误。
在晚上找了一下,发现很多类似的错误。大部分说是没有关 selinux,或者版本不对。但是我的selinux在安装centos时,就关闭了。
看一下日志:
[root@digdeep oracle]# cat /var/log/oracleasm
Creating /dev/oracleasm mount point: /dev/oracleasm
Loading module "oracleasm": failed
Unable to load module "oracleasm"
Loading module "oracleasm": failed
Unable to load module "oracleasm"
... ...
加载oracleasm这个 module 失败。
[root@digdeep oracle]# ls -l /lib/modules/
total 16
drwxr-xr-x 3 root root 4096 Dec 29 19:58 2.6.18-128.el5
drwxr-xr-x 6 root root 4096 Dec 29 17:16 2.6.18-308.24.1.el5
drwxr-xr-x 6 root root 4096 Dec 28 04:29 2.6.18-308.el5
[root@digdeep modules]# find -name oracleasm.ko
./2.6.18-128.el5/kernel/drivers/addon/oracleasm/oracleasm.ko
表明:module oracleasm.ko 确实存在!
但是系统不能调用到:
[root@digdeep oracleasm]# /sbin/insmod oracleasm.ko
[root@digdeep oracleasm]# echo $?
0
[root@digdeep oracle]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting without typing an
answer will keep that current value. Ctrl-C will abort.
Default user to own the driver interface [oracle]:
Default group to own the driver interface [dba]:
Start Oracle ASM library driver on boot (y/n) [y]:
Scan for Oracle ASM disks on boot (y/n) [y]:
Writing Oracle ASM library driver configuration: done
Initializing the Oracle ASMLib driver: [ OK ]
Scanning the system for Oracle ASMLib disks: [ OK ]
错误搞定。
/etc/init.d/oracleasm configure时的错误搞定了,但是在reboot Centos时,又发生了同样的错误:
网上很多说是与kenel的版本不对,于是又重新下载正确的版本的rpm包:
oracleasm-support-2.1.7-1.el5.i386.rpm
oracleasm-2.6.18-308.24.1.el5-2.0.5-1.el5.i686.rpm
oracleasmlib-2.0.4-1.el5.i386.rpm
重新安装:
rpm -Uvh oracleasm-support-2.1.7-1.el5.i386.rpm
rpm -Uvh oracleasm-2.6.18-308.24.1.el5-2.0.5-1.el5.i686.rpm
rpm -Uvh oracleasmlib-2.0.4-1.el5.i386.rpm
然后再 reboot 或者 init 6,发现错误消失:
看来版本正确很重要。
第三个常见的错误是:
ORA-29701: unable to connect to Cluster Manager
解决方法是:
以root身份在$ORACLE_HOME/bin下执行:
localconfig add
如果还不行,则在$ORACLE_HOME/bin执行
localconfig delete
localconfig add
即可解决。
阅读(17477) | 评论(1) | 转发(4) |