[PATCH rhel6-branch] Increment MD container child counter even if its volumes are ignored (#1120640)

David Lehman dlehman at redhat.com
Thu Jul 17 15:30:08 UTC 2014


On 07/17/2014 06:39 AM, Artur Paszkiewicz wrote:
> Volumes which are not selected in Specialized Storage Devices are
> ignored in addUdevDevice. This causes that their parent container
> won't have its child counter incremented, which can later cause an
> incorrect unusedRaidMembersWarning.

Why would you not select all members/components of a container you plan 
to use?

David

>
> Resolves: rhbz#1120640
> Signed-off-by: Artur Paszkiewicz <artur.paszkiewicz at intel.com>
> ---
>   storage/devicetree.py | 7 +++++++
>   1 file changed, 7 insertions(+)
>
> diff --git a/storage/devicetree.py b/storage/devicetree.py
> index 4045cdf..b9ea399 100644
> --- a/storage/devicetree.py
> +++ b/storage/devicetree.py
> @@ -1328,6 +1328,13 @@ class DeviceTree(object):
>                   # slice off the "/dev/" part, lvm filter cares only about the rest
>                   partitions_paths = [p[5:] for p in partitions_paths]
>                   map(lvm.lvm_cc_addFilterRejectRegexp, partitions_paths)
> +
> +            if udev_device_get_md_container(info):
> +                parentName = devicePathToName(udev_device_get_md_container(info))
> +                container = self.getDeviceByName(parentName)
> +                if container:
> +                    container.addChild()
> +
>               return
>
>           log.debug("scanning %s (%s)..." % (name, sysfs_path))
>



More information about the anaconda-patches mailing list