]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/suites/rados: Added wait_for_all_active_clean_pgs flag
authorKamoltat <ksirivad@redhat.com>
Thu, 17 Aug 2023 20:01:38 +0000 (20:01 +0000)
committerKonstantin Shalygin <k0ste@k0ste.ru>
Sat, 17 Aug 2024 11:01:39 +0000 (18:01 +0700)
Added flag to not allow rados suite to delete
the pool unless all pgs are active+clean
and all OSDs are up in the thrashosds side
of the test.

Fixes: https://tracker.ceph.com/issues/59172
Signed-off-by: Kamoltat <ksirivad@redhat.com>
(cherry picked from commit 3ccd10f266cfd7ec6dd1ad930598bfe4ca422a90)

qa/suites/rados/thrash-erasure-code/thrashers/minsize_recovery.yaml
qa/tasks/rados.py

index 771d9a1047a702302953af23d0a0b698de3cc918..f7df20f313f0ebff5e6ba7fbb60603902abecd42 100644 (file)
@@ -13,7 +13,10 @@ overrides:
         osd scrub min interval: 60
         osd scrub max interval: 120
         osd max backfills: 2
+  rados:
+    wait_for_all_active_clean_pgs: true
+
 tasks:
 - thrashosds:
     timeout: 1200
-    chance_test_min_size: 3 
+    chance_test_min_size: 3
index a730a72993c246f0313acc757b3e5b28a8e12124..625ea4d9d7640f38de25f42c84aefb1deb9fe5f4 100644 (file)
@@ -272,6 +272,13 @@ def task(ctx, config):
                     )
                 tests[id_] = proc
             run.wait(tests.values())
+            wait_for_all_active_clean_pgs = config.get("wait_for_all_active_clean_pgs", False)
+            # usually set when we do min_size testing.
+            if  wait_for_all_active_clean_pgs:
+                # Make sure we finish the test first before deleting the pool.
+                # Mainly used for test_pool_min_size
+                manager.wait_for_clean()
+                manager.wait_for_all_osds_up(timeout=1800)
 
             for pool in created_pools:
                 manager.wait_snap_trimming_complete(pool);