Skip to content

Commit 1dd6cf8

Browse files
committed
qa/standalone/scrub: extra delay in osd-scrub-test.sh
Modify TEST_just_deep_scrubs(): The test turns 'no-deep' off, and expects the scrub to be concluded and reported within a short period. But the PG already had a chance to try scrubbing (and fail due to the 'no-deep'), and its 'not-before' was pushed out by osd_scrub_retry_after_noscrub. The fix is to reduce the value of osd_scrub_retry_after_noscrub for this test, and to increase the timeout for the test itself. Fixes: https://tracker.ceph.com/issues/71404 Signed-off-by: Ronen Friedman <[email protected]> (cherry picked from commit cb91678)
1 parent 67b2c5c commit 1dd6cf8

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

qa/standalone/scrub/osd-scrub-test.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -483,6 +483,7 @@ function TEST_just_deep_scrubs() {
483483
# set both 'no scrub' & 'no deep-scrub', then request a deep-scrub.
484484
# we do not expect to see the scrub scheduled.
485485

486+
ceph tell osd.* config set osd_scrub_retry_after_noscrub 2
486487
ceph osd set noscrub || return 1
487488
ceph osd set nodeep-scrub || return 1
488489
sleep 6 # the 'noscrub' command takes a long time to reach the OSDs
@@ -509,10 +510,14 @@ function TEST_just_deep_scrubs() {
509510

510511
# unset the 'no deep-scrub'. Deep scrubbing should start now.
511512
ceph osd unset nodeep-scrub || return 1
512-
sleep 5
513+
sleep 8
513514
declare -A expct_qry_duration=( ['query_last_duration']="0" ['query_last_duration_neg']="not0" )
514515
sc_data_2=()
516+
extract_published_sch $pgid $now_is $now_is sc_data_2
515517
echo "test counter @ should be higher than before the unset: " ${sc_data_2['query_scrub_seq']}
518+
519+
declare -A expct_qry_duration=( ['query_last_duration']="0" ['query_last_duration_neg']="not0" )
520+
sc_data_2=()
516521
wait_any_cond $pgid 10 $saved_last_stamp expct_qry_duration "WaitingAfterScrub " sc_data_2 || return 1
517522
perf_counters $dir ${cluster_conf['osds_num']}
518523
}

0 commit comments

Comments
 (0)