I recently had to setup multiple hosts using Emulex fiber HBAs connecting to a Fiber channel array through 2 SAN switches with redundant paths. Here are some notes that helped me get the job done.
Linux multipathing (Mpathd)
config file: /etc/multipath.conf
Remark the black list all devices section. This will turn on multipathing for all default devices. e.g.
# Blacklist all devices by default.
# on the default devices.
#Remove the following to enable multipathing
# devnode “*”
Questions to ask yourself.
What HBAs (scsi_hosts) are using the lpfc (emulex) driver?
All scsi_hosts bound to the LPFC driver can be viewed with the following command:
ls -d /sys/bus/pci/drivers/lpfc/*/host*
How do I rescan an adapter (host1) for new targets?
echo “- – -” > /sys/class/scsi_host/host1/scan
How do I decide what multipathing to use with an array? e.g. Should I use RDAC (for sun) ,Powerpath (for EMC) or use the native Linux MPathd
Look at array’s installation guide, it will tell you which to use, it can vary, depending on the HBA and host operating system used.
If it states to use mpathd, use the following to verify that the Array is supported natively by your currently installed version of mpathd.
multipathd -k; show config
Then look at HBA install guide for specific instructions to setup the HBA.
Is the link up?
What is my HBA port WWN(s)?
What devices do I see?
“fdisk -l” will show active paths ONLY, look in /var/log/messages for inactive paths – they will have I/O errors, which is expected as long as it is an active/passive array.
scsi_id -g -s /block/sd[d,e,f,etc] (shows lun UUID)
What paths do I see to what devices?
(after multipathing is enabled) multipath -ll or multipath -v2
(before multipathing is enabled) use fdisk -l to confirm the /dev/sdX is same by issuing “scsi_id -g -s /block/sd[d,e,f,etc]”
cat /proc/scsi/scsi (this will show paths seen)