From 627faf142e1d81f5a299811d101afa8b92213e7d Mon Sep 17 00:00:00 2001 From: Paul Maidment Date: Thu, 25 Jul 2024 16:49:28 +0300 Subject: [PATCH] The purpose of this PR is to pick up a change to disk cleanup made in rh-ecosystem-edge/preinstall-utils@cf01558 This change is to ensure that in the case of thin provisioning we clean up all necessary disks in the correct order. This has been tested in assisted-test infra with a 5 node cluster and an artificially created thin provisioning, the cluster installs correctly where it would not have done so before this change. It was discovered that disk cleanup does not clean disks in every scenario. When thin provisioned disk mappings are present, the existing installer is not able to clean them up. this is because the `_tdata` and `_tmeta` mappings are the only mappings that will be returned when filtering by associated disk. The changed library code ensures that we search for a base DM and then order the DMs correctly so that deletion will be performed in the correct order. Certain customers were running into the scenario above when they have thin volume provisioning. For more context, please see the commit here We derive a name for the base DM using the function `getBaseDMDevicesForThinProvisioning` and we ensure proper delete order is adhered to using `sortDMDevicesForDeletion` This has been tested as part of an assisted-service deployment using assisted-test-infra to create a 5 node cluster. Some thin volumes were created and linked to the installation disk. These were cleaned correctly when they would not have been cleaned before.