This is a workaround to allow installation to a single path of a multipath in the event that multipathd loses the race to claim the member disks during system startup. This patch does nothing to make the resulting system use multipath, so it is on the user to manually reconfigure their system after installation.
I don't really want this on master since this should be fixed outside of blivet/anaconda. If anyone disagrees, let me know.
If multipath loses the race to claim the member disks and something like lvm activates devices on one of the members, allow direct use of that member and ignore the others. This allows configuration to continue, but without the benefits of multipath. --- blivet/devicetree.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
diff --git a/blivet/devicetree.py b/blivet/devicetree.py index 8a79f14..e47793b 100644 --- a/blivet/devicetree.py +++ b/blivet/devicetree.py @@ -1027,6 +1027,20 @@ class DeviceTree(object): # make sure any device we found is an md device device = None
+ # If multipath loses the race to claim the member disks they can have + # stuff like lvm activated on the member, in which case we just ignore + # the other members completely. In this case the user will have to + # convert to using multipath after installation. + if udev_device_is_disk(info) and not device: + serial = udev_device_get_serial(info) + path = "/dev/%s" % info["DEVNAME"] + if serial and self.getDevicesBySerial(serial) and \ + not devicelibs.mpath.is_multipath_member(path): + log.warning("ignoring apparent multipath member %s ; it " + "looks as if multipath lost the race to claim it" + % name) + return + if device and device.isDisk and \ devicelibs.mpath.is_multipath_member(device.path): # mark as multipath_member also when repopulating devicetree
On Mon, 2014-02-24 at 15:55 -0600, David Lehman wrote:
If multipath loses the race to claim the member disks and something like lvm activates devices on one of the members, allow direct use of that member and ignore the others. This allows configuration to continue, but without the benefits of multipath.
blivet/devicetree.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
diff --git a/blivet/devicetree.py b/blivet/devicetree.py index 8a79f14..e47793b 100644 --- a/blivet/devicetree.py +++ b/blivet/devicetree.py @@ -1027,6 +1027,20 @@ class DeviceTree(object): # make sure any device we found is an md device device = None
# If multipath loses the race to claim the member disks they can have# stuff like lvm activated on the member, in which case we just ignore# the other members completely. In this case the user will have to# convert to using multipath after installation.if udev_device_is_disk(info) and not device:serial = udev_device_get_serial(info)path = "/dev/%s" % info["DEVNAME"]if serial and self.getDevicesBySerial(serial) and \not devicelibs.mpath.is_multipath_member(path):log.warning("ignoring apparent multipath member %s ; it ""looks as if multipath lost the race to claim it"% name)returnif device and device.isDisk and \ devicelibs.mpath.is_multipath_member(device.path): # mark as multipath_member also when repopulating devicetree
ACK for the rhel7-branch
anaconda-patches@lists.fedorahosted.org