From 50130328450d1f624d30438ca835d40e0d4f942d Mon Sep 17 00:00:00 2001 From: Jonathan Brassow Date: Thu, 2 Nov 2017 08:53:48 -0500 Subject: [PATCH] testsuite: Add and document a 'should' for "idle" -> "recover" RAID test When a "recover" is just starting for a RAID LV, it is possible to get "idle" for the sync action if the status is issued quickly enough. This is fine, the MD thread just hasn't gotten things going yet. However, the /need/ for a "recover" should be marked in md->recovery and it would be simple enough to fix the kernel so this doesn't happen. May eventually want a separate bug for this, but for now it fits with RHBZ 1507719. --- test/shell/lvconvert-raid-status-validation.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/test/shell/lvconvert-raid-status-validation.sh b/test/shell/lvconvert-raid-status-validation.sh index 9ffaaf380..3e91d23be 100644 --- a/test/shell/lvconvert-raid-status-validation.sh +++ b/test/shell/lvconvert-raid-status-validation.sh @@ -83,7 +83,12 @@ while true; do # If the sync operation ("recover" in this case) is not # finished, then it better be as follows: [ "${a[5]}" = "Aa" ] - [ "${a[7]}" = "recover" ] + + # Might be transitioning from "idle" to "recover". + # Kernel could check mddev->recovery for the intent to + # begin a "recover" and report that... probably would be + # better. RHBZ 1507719 + should [ "${a[7]}" = "recover" ] else # Tough to tell the INVALID case, # Before starting sync thread: "Aa X/X recover" -- 2.43.5