本文是一次两台IBM x240安装OEL6.5x64连接IBM V3500存储多路径配置过程记录,当时用于安装Oracle 11g rac集群环境的。  
IBM v3500系列存储由于官方不再提供多路径软件,比原来DS系列的存储麻烦一点了,只好采用发行版自带的device-mapper多路径软件包实现。 本文出自:http://koumm.blog.51cto.com/

1. 本机环境

p_w_picpath

适用于RHEL/CentOS 6.x系统。

2. 安装device-mapper软件包如下,缺包自行安装。

[root@node1 ~]# rpm -qa|grep device-mapper    
device-mapper-libs-1.02.79-8.el6.x86_64    
device-mapper-multipath-libs-0.4.9-72.0.1.el6.x86_64    
device-mapper-event-libs-1.02.79-8.el6.x86_64    
device-mapper-event-1.02.79-8.el6.x86_64    
device-mapper-persistent-data-0.2.8-2.el6.x86_64    
device-mapper-multipath-0.4.9-72.0.1.el6.x86_64    
device-mapper-1.02.79-8.el6.x86_64    
[root@node1 ~]#

3. 连接存储配置过程略。

抄下服务器两块HBA的wwn号码后在存储上进行配置,能适别到盘就可以了,存储上划分了一个2G,450G,450G,450G,450G,其它都是多路径重复。

OEL6.X IBM v3500存储多路径配置_第1张图片

 

4.  识别磁盘udev号码

for i in a b c d e f g h i j k l m n o p q  ; do echo "KERNEL==\"sd*\", BUS==\"scsi\", PROGRAM==\"/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/\$name\", RESULT==\"`/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\", GROUP=\"asmadmin\", MODE=\"0660\""  ; done

说明:号码都是8,9,a,b,c重复,f是单独挂载磁盘不用列入。找到磁盘UDEV号码。

上面本来是想采用udev方式配置oracle grid磁盘的,没有成功,最后采用asm磁盘进行配置成功。

OEL6.X IBM v3500存储多路径配置_第2张图片

可以直接手动收集号码

OEL6.X IBM v3500存储多路径配置_第3张图片

 

 

5. 根据udev号码创建multipath配置文件

配置文件如下:

[root@node1 ~]# cat /etc/multipath.conf

defaults { 
user_friendly_names no 
queue_without_daemon no 
flush_on_last_del yes 
max_fds max 

blacklist { 
devnode "^hd[a-z]" 
devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*" 
devnode "^cciss.*" 

devices { 
        device { 
                vendor                  "IBM " 
                product                 "LUN" 
                path_grouping_policy    group_by_prio 
                features                "3 queue_if_no_path pg_init_retries 50" 
                getuid_callout          "/sbin/scsi_id --whitelisted --replace-whitespace --device=/dev/%n" 
                path_checker            tur 
                path_selector           "round-robin 0" 
                hardware_handler        "1 alua" 
                failback                immediate 
                rr_weight               uniform 
                rr_min_io               128 
        } 

multipaths { 
        multipath { 
                wwid                    360050763008080cd2000000000000008  
                alias                   crs 
                uid                     501                                                
                gid                     504                                              
        } 
        multipath { 
                wwid                    360050763008080cd2000000000000009    
                alias                   data1                                     
                uid                     501                                                
                gid                     504                                               
         } 
        multipath { 
                wwid                    360050763008080cd200000000000000a    
                alias                   data2                                     
                uid                     501                                                
                gid                     504                                               
         } 
        multipath { 
                wwid                    360050763008080cd200000000000000b    
                alias                   data3                                     
                uid                     501                                                
                gid                     504                                               
         } 

        multipath { 
                wwid                    360050763008080cd200000000000000c    
                alias                   recovery                                     
                uid                     501                                                
                gid                     504                                               
         } 

配置multipath服务。

chkconfig multipathd on  
chkconfig --level 345 multipathd on    
modprobe dm-multipath    
service  multipathd restart

查看结果,配置成功。

OEL6.X IBM v3500存储多路径配置_第4张图片