Passing --update=super-minor to mdadm for containers and sets there in leads to corrupt superblocks, see: bug rh523320, work around this for now by not passing --update=super-minor in these cases. --- storage/devicelibs/mdraid.py | 11 ++++++++--- storage/devices.py | 5 +++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/storage/devicelibs/mdraid.py b/storage/devicelibs/mdraid.py index ade42fd..b082c7b 100644 --- a/storage/devicelibs/mdraid.py +++ b/storage/devicelibs/mdraid.py @@ -164,7 +164,8 @@ def mdadd(device, no_degraded=False): if rc: raise MDRaidError("mdadd failed for %s" % device) -def mdactivate(device, members=[], super_minor=None, uuid=None): +def mdactivate(device, members=[], super_minor=None, update_super_minor=False, + uuid=None): if super_minor is None and not uuid: raise ValueError("mdactivate requires either a uuid or a super-minor") @@ -175,13 +176,17 @@ def mdactivate(device, members=[], super_minor=None, uuid=None): else: identifier = "" + if update_super_minor: + extra_args = ["--update=super-minor"] + else: + extra_args = [ ] + rc = iutil.execWithRedirect("mdadm", ["--assemble", device, identifier, "--run", - "--auto=md", - "--update=super-minor"] + members, + "--auto=md"] + extra_args + members, stderr = "/dev/tty5", stdout = "/dev/tty5", searchPath=1) diff --git a/storage/devices.py b/storage/devices.py index 756b9b2..b4b7aa5 100644 --- a/storage/devices.py +++ b/storage/devices.py @@ -2438,9 +2438,14 @@ class MDRaidArrayDevice(StorageDevice): member.setup() disks.append(member.path) + update_super_minor = True + if self.type == "mdcontainer" or self.devices[0].type == "mdcontainer": + update_super_minor = False + mdraid.mdactivate(self.path, members=disks, super_minor=self.minor, + update_super_minor=update_super_minor, uuid=self.uuid) udev_settle() -- 1.6.4.2 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list