Device Mapper Multipath Configuration

1. Setup Steps

1.1 install and load device mapper (not necessary in RHEL58)

a) install Device Mapper Multipath/DMMP

yum install device-mapper device-mapper-multipath

b) load and check device mapper and multipath modules

modprobe dm-multipath
modprobe dm-round-robin
lsmod | grep md

c) start the multipathd service

service multipathd start

d) enable multipathd service at startup

chkconfig multipathd on

 

1.2. edit the configuration file

vim /etc/multipath.conf

Here is my config file.

defaults {
user_friendly_names             yes
path_grouping_policy            group_by_prio

failback                        immediate
no_path_retry                  fail
prio_callout                    "/sbin/mpath_prio_alua %d"
}

blacklist {
devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"
devnode "^sda"
}

1.3. restart service with configuration file

a) restart service

service multipathd restart

b) flush all multipath device maps

multipath -F

c) check log of multipath for any warnings and errors

multipath -v2

d) check multipath topology

multipath -ll

 

2. Configuration Result

2.1 check the RAID status using iprconfig

iprconfig -c show-config | grep RAID
0000:01:00.0/1:            PCI-E SAS RAID Adapter    Operational
sdb    0000:01:00.0/1:2:0:0       RAID 0 Disk Array         Optimized
sdc    0000:01:00.0/1:2:1:0       RAID 0 Disk Array         Optimized
sdd    0000:01:00.0/1:2:2:0       RAID 5 Disk Array         Optimized
sdh    0000:01:00.0/1:2:3:0       RAID 10 Disk Array        Optimized
sdj    0000:01:00.0/1:2:4:0       RAID 0 Disk Array         Non-Optimized
0001:01:00.0/2:            PCI-E SAS RAID Adapter    Operational
sde    0001:01:00.0/2:2:0:0       RAID 0 Disk Array         Non-Optimized
sdf    0001:01:00.0/2:2:1:0       RAID 0 Disk Array         Non-Optimized
sdg    0001:01:00.0/2:2:2:0       RAID 5 Disk Array         Non-Optimized
sdi    0001:01:00.0/2:2:3:0       RAID 10 Disk Array        Non-Optimized
sdk    0001:01:00.0/2:2:4:0       RAID 0 Disk Array         Optimized

2.2 multipath status

multipath -ll
mpath2 (1IBM_IPR-0_28902A3E15E61ED8) dm-1 IBM,IPR-0   28902A3E
[size=264G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=50][active]
\_ 1:2:1:0 sdc 8:32  [active][ready]
\_ round-robin 0 [prio=10][enabled]
\_ 2:2:1:0 sdf 8:80  [active][ready]
mpath1 (1IBM_IPR-0_A2152AAE109F2388) dm-0 IBM,IPR-0   A2152AAE
[size=264G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=50][active]
\_ 1:2:0:0 sdb 8:16  [active][ready]
\_ round-robin 0 [prio=10][enabled]
\_ 2:2:0:0 sde 8:64  [active][ready]
mpath5 (1IBM_IPR-0_40402E00000003A0) dm-4 IBM,IPR-0   40402E00
[size=529G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=50][active]
\_ 2:2:4:0 sdk 8:160 [active][ready]
\_ round-robin 0 [prio=10][enabled]
\_ 1:2:4:0 sdj 8:144 [active][ready]
mpath4 (1IBM_IPR-10_40402E0000000380) dm-3 IBM,IPR-10  40402E00
[size=130G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=50][active]
\_ 1:2:3:0 sdh 8:112 [active][ready]
\_ round-robin 0 [prio=10][enabled]
\_ 2:2:3:0 sdi 8:128 [active][ready]
mpath3 (1IBM_IPR-5_4F8C3CB60A8CB5C0) dm-2 IBM,IPR-5   4F8C3CB6
[size=260G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=50][active]
\_ 1:2:2:0 sdd 8:48  [active][ready]
\_ round-robin 0 [prio=10][enabled]
\_ 2:2:2:0 sdg 8:96  [active][ready]

 

2.3 Conclusion

You can see with current config file, multipath used the correct asymmetric access status from our RAID utility.

Leave a Reply

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