Operating System - Linux
1824245 Members
3667 Online
109669 Solutions
New Discussion юеВ

Migration PowerPath to Linux multipath

 
MSwift
Regular Advisor

Migration PowerPath to Linux multipath

I am in the process of migrating from PowerPath to Linux device-mapper multipath. My plan is as follows.

1. Backup current VG's
2. remove PowerPath and uninstall it
3. de-commision the VG.
4. configure device-mapper-multipath
5. create new VG's and restore data.

Is there any other way of doing this migration without the backup/restore idea? Please help..

Thanks

Mike.
7 REPLIES 7
MSwift
Regular Advisor

Re: Migration PowerPath to Linux multipath

Thanks for the DOCS..But our boot disks are not SAN. Only our Data is on SAN. With that in mind would there be a better way to do this conversion without the backup/restore that i have mentioned above!

Thanks

Mike.
Matti_Kurkela
Honored Contributor

Re: Migration PowerPath to Linux multipath

When you change your multipath solution, you're only changing the way your system handles *access* to the storage LUNs. The actual *data* on those LUNs does not need to change one bit.

I'd do something like this:

1.) Contact the SAN administrator and make sure s/he knows how to present LUNs for Linux dm-multipath (may require different options at the SAN side than PowerPath; have him/her check the appropriate documentation from the SAN manufacturer)

2.) Unmount the data disks, shutdown any raw databases, and deactivate the VGs (vgchange -a n ).

3.) Remove and un-install PowerPath

4.) Configure device-mapper-multipath and make the appropriate changes to the LVM configuration: with PowerPath, your LVM should be configured to use only PowerPath devices/prefer them over anything else. Now LVM should be configured to use dm-multipath devices instead.

5.) Run "multipath -v2" to initialize the multipath configuration, then make sure the multipathd daemon is running and configured to start at boot time.

6.) Run "vgscan". It should automatically figure out that your VGs are now accessible through dm-multipath devices. Verify with commands like "pvs", "vgs". Make sure LVM uses dm-multipath devices, not /dev/sd* devices.

7.) Activate your VGs again (vgchange -a y). Mount filesystems; etc.

8.) Remember to re-create your initrd, to remove the last traces of PowerPath & to include your new LVM and dm-multipath configurations. You might want to reboot to make sure the system can boot without issues.

MK
MK
MSwift
Regular Advisor

Re: Migration PowerPath to Linux multipath

Thanks MK!

Points 1,2,3 are fine.

Point 4 you are referring to, is it to deal with the lvm.vonf filtering?

Point 5,6 and 7 are fine.

Could you please give an example for point 8 to re-create initrd in this case?

Thanks again!

Best Regards

Mike.
Matti_Kurkela
Honored Contributor

Re: Migration PowerPath to Linux multipath

> Point 4 you are referring to, is it to deal with the lvm.conf filtering?

Yes, filtering and/or the "preferred_names" setting in lvm.conf, if your Linux distribution has it.

Filtering is stricter, and if you have used PowerPath correctly, you probably already know how to use it; the "preferred_names" setting can be more flexible if you have a significant number of local disks in addition to SAN LUNs, but it isn't available in all versions (e.g. the early update levels of RHEL 4). Either can be used to make LVM use multipathed devices.

Example for initrd creation for RHEL: (replace the kernel version number with the kernel you're actually using)

mv /boot/initrd-2.6.18-194.17.1.el5.img /boot/initrd-2.6.18-194.17.1.el5.img.old

mkinitrd -v /boot/initrd-2.6.18-194.17.1.el5.img 2.6.18-194.17.1.el5

In other distributions, the procedure might be different; check the documentation of your Linux distribution.

Once you've confirmed the new version works, remember to delete the initrd-*.img.old file.

MK
MK
MSwift
Regular Advisor

Re: Migration PowerPath to Linux multipath

Thanks again MK!

I have a test server that i could try this..actually i am seeing the SAN using PowerPath and DMM and i have verified it. Let me try this and post results.

Best Regards

Mike
MSwift
Regular Advisor

Re: Migration PowerPath to Linux multipath

Hello MK!

UPDATE...

Here are the steps i followed..

umount /test
vgchange -a n testvg
rpm -e
multipath -v2
pvscan (is this reqd?)
vgscan -vvvv
vgchange -a y testvg
mount /dev/testvg/testvol /test
verify data in /test (looks good)
make a new initrd...

reboot..

Everything was fine.

One question..

When i changed the LVM filter from the default to use the mpath (after i turned the multipath, i lost the vg's

# By default we accept every block device:
filter = [ "a/.*/" ]
#filter = [ "a|/dev/mapper/mpath.*|", "r|.*|" ]

But when i changed back to the default it worked fine. So is it better to leave this at default when using DMM?

Best Regards

Mike.