如何诊断ASMLIB故障

虽然我并不推荐你使用ASMLIB绑定设备名, 详见这篇文章《Why ASMLIB and why not?》 。  但大概因为介绍ASMLIB的文章远多于UDEV的缘故, 导致有大量对RAC安装配置不太熟悉的朋友仍执意采用ASMLIB,又因为ASMLIB的配置不算太简单所以在实际安装RAC之前的ASMLIB实施过程中有不少人遇到了问题, 其次在ASMLIB的使用过程中麻烦也不少。

这里总结了一下ASMLIB的诊断思路, 如下脚本:

 

cat /etc/sysconfig/oracleasm


1) uname -a
2) rpm -qa | grep ^oracleasm
3) rpm -V oracleasmlib
4) multipath -ll

1) output of command line

# rpm -V oracleasm-support

# /etc/init.d/oracleasm scandisks

# /etc/init.d/oracleasm listdisks

# ls -l -R /dev/oracleasm/

# ls -l /etc/sysconfig/oracleasm

# cat /etc/sysconfig/oracleasm

# mount

2) oracleasm log file

/var/log/oracleasm

3) sosreport

By default the "sos" package should be installed into EL4u6 or later.
(If not, please download the sos package from ULN https://linux.oracle.com)

You just need type command "sosreport" as root user, and press "Enter" or "yes" for all the questions.

The sosreport will run for several minutes, according to different system, the running time might be more longer.
Once completed, "sosreport" will generate a compressed sosreport-xx-xx.bz2 file under /tmp. 


[summary]
- confirm system build asm disk on muoltipath devices
- modify /etc/udev/rules.d.90-dm.rules
- currently both nodes could find the asm disk from scandisks and listdisks
- sharon.honor will try installer again, if necessary need get help from application(RAC) team


1. Reboot the box.

2. Run the following commands
#fdisk -l
#multipath -ll
#blkid
#cat /etc/sysconfig/oracleasm
#cat /etc/sysconfig/oracleasm-_dev_oracleasm

#uptime
#/etc/init.d/oracleasm start
#/etc/init.d/oracleasm listdisks

#uptime
#/etc/init.d/oracleasm scandisk

Please also modify the /etc/sysconfig/oracleasm-_dev_oracleasm with below.
ORACLEASM_SCANORDER="dm"
ORACLEASM_SCANEXCLUDE="sd"


The devices that asmlib will scan is controlled in the /etc/sysconfig/oracleasm file 
with the "scanorder" and "scanexclude" parameters.

Posted

in

by

Tags:

Comments

6 responses to “如何诊断ASMLIB故障”

  1. suredandan Avatar
    suredandan

    /etc/init.d/oracleasm scandisk 这个应该是/etc/init.d/oracleasm scandisks

  2. […]  在Linux 6上使用UDEV解决RAC ASM存储设备名问题 利用UDEV服务解决RAC ASM存储设备名 Why ASMLIB and why not? 如何诊断ASMLIB故障 […]

  3. […] 为什么RHEL 6上没有ASMLIB?  http://www.askmaclean.com/archiv … -redhat-linux6.html 如何诊断ASMLIB故障  : http://www.askmaclean.com/archiv … 95%85%e9%9a%9c.html […]

  4. Ask_Maclean_liu_Oracle Avatar

    1. The scanorder was not set in /etc/sysconfig/oracleasm. When Device Mapper is used, the parameter ORACLEASM_SCANORDER should be set to “dm”Please seeNote 602952.1 – How To Setup ASM & ASMLIB On Native Linux Multipath MapperConfiguring Oracle ASMLib on Multipath Diskshttp://www.oracle.com/technetwork/topics/linux/multipath-097959.html2. The /etc/sysconfig/oracleasm should be a symbolic link pointing to /etc/sysconfig/oracleasm-_dev_oracleasmFor example:lrwxrwxrwx 1 root root 24 Apr 13 06:54 /etc/sysconfig/oracleasm -> oracleasm-_dev_oracleasm3. When using ASMLIB, asm_diskstring should be unset or set to ‘ORCL:*’. I can see the asm_diskstring was set to ‘/dev/oracleasm/disks/*’. When doing so, it’s bypassing the ASMLIB library calls as if ASMLIB is not used. You can check LIBRARY column in v$asm_disk view to see the difference as a proof. Please correct this when ready using the following note. Note 1077094.1 Ext/Pub How to fix the DiscoveryString in profile.xml if set wrongly 4. Once above issues are fixed on all nodes, please restart CRS on each node. If ASM is still with INTERMEDIATE state, please check whether ocssd.bin process is started. # ps -ef|grep ocssd.binIf yes, please then manually login to ASM instance with sqlplus and manually mount the OCRVD diskgroup then manually start the cluster with the following command. # crsctl start cluster 5. Once CRS is started, please manually mount the other diskgroups if they are not mounted automatically by CRS. Once they are mounted, please proceed with the diskgroup drop as needed.

Leave a Reply to 深入了解Oracle ASM(一):基础概念 | Ask Maclean Oracle Blog Cancel reply

Your email address will not be published. Required fields are marked *