How do I configure device-mapper-multipath?
Solution:
1. Verify that your device-mapper and multipath driver are at least the version shown below or higher by running the command: rpm -qa | grep device-mapperdevice-mapper-1.02.28-2.el5
device-mapper-multipath-0.4.7-23.el5.4.0.1
device-mapper-event-1.02.28-2.el5
2. Identify your local disks i.e. /dev/sda. Once your local disk is determined run the following command to obtain its scsi_id: scsi_id –gus /block/sda
360024e805314c20011faf391033bdece
3. Open the /etc/multipath.conf file and locate and comment out the section below:
#blacklist {
# devnode “*”
#}
4. Once the scsi_id of your local disk has been retrieved, you must blacklist this scsi_id from being used as a multipath device. Within /etc/multipath.conf file and locate, uncomment, and modify the section below:
blacklist {
wwid <enter your local disk scsi_id here>
devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"
devnode "^hd[a-z]"
}
5. Uncomment your defaults section within your /etc/multipath.conf
defaults {
udev_dir /dev
polling_interval 10
selector "round-robin 0"
path_grouping_policy multibus
getuid_callout "/sbin/scsi_id -g -u -s /block/%n"
prio_callout /bin/true
path_checker readsector0
rr_min_io 100
max_fds 8192
rr_weight priorities
failback immediate
no_path_retry fail
user_friendly_names yes
}
6. Locate the multipaths section within your /etc/multipath.conf file. In this section you will provide the scsi_id of each iSCSI volume and provide an alias in order to keep a consistent naming convention across all of your OVM Server nodes. An example is shown below:multipaths {
multipath {
wwid <scsi_id of volume1>
alias alias_of_volume1
}
multipath {
wwid <scsi_id of volume2>
alias alias_of_volume2
}
}
7. Restart your multipath daemon service using the following command:
service multipathd restart
8. Verify that your multipath volumes alias are displayed properly by running the following command:multipath –ll
Alias_of_volume1 (scsi_id of volume1) dm-2 EQLOGIC,100E-00
[size=220G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=0][active]
\_ 6:0:0:0 sdaj 66:48 [active][ready]
\_ 4:0:0:0 sdag 66:0 [active][ready]
\_ 3:0:0:0 sdd 8:48 [active][ready]
\_ 5:0:0:0 sdn 8:208 [active][ready]
9. Make sure the iSCSI service starts upon boot using the command:
chkconfig multipathd on
device-mapper-event-1.02.28-2.el5
2. Identify your local disks i.e. /dev/sda. Once your local disk is determined run the following command to obtain its scsi_id: scsi_id –gus /block/sda
360024e805314c20011faf391033bdece
3. Open the /etc/multipath.conf file and locate and comment out the section below:
#blacklist {
# devnode “*”
#}
4. Once the scsi_id of your local disk has been retrieved, you must blacklist this scsi_id from being used as a multipath device. Within /etc/multipath.conf file and locate, uncomment, and modify the section below:
blacklist {
wwid <enter your local disk scsi_id here>
devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"
devnode "^hd[a-z]"
}
5. Uncomment your defaults section within your /etc/multipath.conf
defaults {
udev_dir /dev
polling_interval 10
selector "round-robin 0"
path_grouping_policy multibus
getuid_callout "/sbin/scsi_id -g -u -s /block/%n"
prio_callout /bin/true
path_checker readsector0
rr_min_io 100
max_fds 8192
rr_weight priorities
failback immediate
no_path_retry fail
user_friendly_names yes
}
6. Locate the multipaths section within your /etc/multipath.conf file. In this section you will provide the scsi_id of each iSCSI volume and provide an alias in order to keep a consistent naming convention across all of your OVM Server nodes. An example is shown below:multipaths {
multipath {
wwid <scsi_id of volume1>
alias alias_of_volume1
}
multipath {
wwid <scsi_id of volume2>
alias alias_of_volume2
}
}
NOTE: | Additional multipath subsections can be added to meet the number of volumes you need. |
7. Restart your multipath daemon service using the following command:
service multipathd restart
8. Verify that your multipath volumes alias are displayed properly by running the following command:multipath –ll
Alias_of_volume1 (scsi_id of volume1) dm-2 EQLOGIC,100E-00
[size=220G][features=0][hwhandler=0][rw]
\_ round-robin 0 [prio=0][active]
\_ 6:0:0:0 sdaj 66:48 [active][ready]
\_ 4:0:0:0 sdag 66:0 [active][ready]
\_ 3:0:0:0 sdd 8:48 [active][ready]
\_ 5:0:0:0 sdn 8:208 [active][ready]
9. Make sure the iSCSI service starts upon boot using the command:
chkconfig multipathd on
No comments:
Post a Comment