Went to a customer today to move a DS4000 directly connected RH5 update 3 linux server to then go through an SVC with Image mode disks.
The device-mapper and device-mapper-multipath were aleady installed. I copied the /etc/multipath.conf from the SVC site ver 3.01 and edited to "blacklist" the sas internal disks.
I then "chkconfig multipathd on" and shutdown. I also commented out all the non system filesystems then shutdown. I then mapped the DS4000 LUNs through the SVC as image mode disks.
I powered up the box and then managed to mount all the filesystems that use LVM. There were two filesystems that however were configured the old fashioned way by creating a partition and creating a filesystem on it (orig /dev/sdc1). But even this I managed to find the mpath device for so I mounted the filesystem from /dev/mapper/mpath6p1. This worked fine, but when I added this to the /etc/fstab file and rebooted. The system stopped whilst trying to fsck that filesystem saying that the device was not present or found. It was as if the mpath6 device wasn't created as of yet.
I then added the device-mapper and multipath-round-robin to /etc/modprobe.conf and created a new mkinitrd compressed boot image. However, this did not contain the multpathing modules. I found the modules by doing a lsmod and adding the exact name into /etc/modprobe.conf, one per line.
I tried again but again the same thing happened. The LVM filesystems obviously mounted fine because they were using VGs that pointed to PVIDs not actual devices.
So I would be grateful if someone can give me an insite as to where I went wrong please.
SystemAdmin 110000D4XK706 Posts
Re: Device-mapper and Multipathing2009-06-30T23:48:16ZThis is the accepted answer. This is the accepted answer.You do not need to have multipath modules and tools in your initrd image to have support for multipath devices in /etc/fstab. You need to have them
in the initrd image only if one of your boot devices (root or swap is a multipathed device).
To be doubly sure (before I respond), I just verified it works as expected in my RHEL 5.3 installation.
When the boot fails can you login and check if the directory /dev/mapper is populated and the naming of the partitioned device is same as what you have
specified in your /etc/fstab (i.e mpath0p1 Vs mpath0pap1)
malahal 1100009N014 Posts
Re: Device-mapper and Multipathing2009-07-01T18:57:35ZThis is the accepted answer. This is the accepted answer.multipath uses /var/lib/multipath/bindings file to get user friendly names like mpath0 (mpath0p1 for a partition). If you happen to have that file in a separate file system (where is your /var file system?), then you will get wwid based names (like /dev/mapper/<wwid>) until that file appears and the multipathd service is run.
I don't know any easier way to avoid this (I think a fix may be on its way to keep the bindings file in /etc file system) other than (1) findings scripts calling multipath and run them all with "-b" option or (2) create that file in "/" file system image (unmount /var and then create such file).