TEST-64-UDEV-STORAGE: clear MD superblock on exit

Workaround for issue #38240.
This commit is contained in:
Yu Watanabe
2025-07-29 14:32:25 +09:00
parent f48068a379
commit 5ad6fe9850
+12
View File
@@ -1186,6 +1186,12 @@ EOF
helper_check_device_units
# Cleanup
mdadm -v --stop "$raid_dev"
# Clear superblocks to make the MD device will not be restarted even if the VM is restarted.
# This is a workaround for issue #38240.
mdadm -v --zero-superblock --force "${devices[@]}"
udevadm settle --timeout=30
# Check if all expected symlinks were removed after the cleanup
udevadm wait --settle --timeout=30 --removed "${expected_symlinks[@]}"
helper_check_device_units
@@ -1243,6 +1249,12 @@ testcase_mdadm_lvm() {
# Cleanup
lvm vgchange -an "$vgroup"
mdadm -v --stop "$raid_dev"
# Clear superblocks to make the MD device will not be restarted even if the VM is restarted.
# This is a workaround for issue #38240.
mdadm -v --zero-superblock --force "${devices[@]}"
udevadm settle --timeout=30
# Check if all expected symlinks were removed after the cleanup
udevadm wait --settle --timeout=30 --removed "${expected_symlinks[@]}"
helper_check_device_units