From: Sridhar Seshasayee Date: Wed, 16 Jun 2021 11:26:54 +0000 (+0530) Subject: qa/standalone/osd: Modify osd tests for mclock scheduler X-Git-Tag: v17.1.0~1244^2~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=2c577040cbcb5cedc22ab1dd0ac9d4504b424e56;p=ceph.git qa/standalone/osd: Modify osd tests for mclock scheduler Modified test cases: 1. osd-recovery-prio.sh: Set osd_op_queue = wpq for all tests since mclock doesn't consider recovery priority as part of its scheduling algorithm. 2. osd-recovery-stats.sh: a. TEST_recovery_undersized(): - Set osd_mclock_profile to high_recovery_ops profile. - Increase wait for recovery timeout to 300 secs. 3. osd-rep-recov-eio.sh: a. TEST_rep_backfill_unfound(): - Set osd_mclock_profile to high_recovery_ops profile. - Increase wait for backfill_unfound to 360 secs. 4. repeer-on-acting-back.sh: a. TEST_repeer_on_down_act(): - Set osd_mclock_profile to high_recovery_ops profile. (To improve the test duration) Signed-off-by: Sridhar Seshasayee --- diff --git a/qa/standalone/osd/osd-recovery-prio.sh b/qa/standalone/osd/osd-recovery-prio.sh index f5d7928c8511..02b65f67a270 100755 --- a/qa/standalone/osd/osd-recovery-prio.sh +++ b/qa/standalone/osd/osd-recovery-prio.sh @@ -25,7 +25,10 @@ function run() { export CEPH_MON="127.0.0.1:7114" # git grep '\<7114\>' : there must be only one export CEPH_ARGS CEPH_ARGS+="--fsid=$(uuidgen) --auth-supported=none " - CEPH_ARGS+="--mon-host=$CEPH_MON --osd_max_backfills=1 --debug_reserver=20" + CEPH_ARGS+="--mon-host=$CEPH_MON --osd_max_backfills=1 --debug_reserver=20 " + # Set osd op queue = wpq for the tests. Recovery priority is not + # considered by mclock_scheduler leading to unexpected results. + CEPH_ARGS+="--osd-op-queue=wpq " export objects=200 export poolprefix=test export FORCE_PRIO="255" # See OSD_RECOVERY_PRIORITY_FORCED diff --git a/qa/standalone/osd/osd-recovery-stats.sh b/qa/standalone/osd/osd-recovery-stats.sh index 7d88e98a0c09..42347510f6aa 100755 --- a/qa/standalone/osd/osd-recovery-stats.sh +++ b/qa/standalone/osd/osd-recovery-stats.sh @@ -28,6 +28,8 @@ function run() { CEPH_ARGS+="--mon-host=$CEPH_MON " # so we will not force auth_log_shard to be acting_primary CEPH_ARGS+="--osd_force_auth_primary_missing_objects=1000000 " + # Use "high_recovery_ops" profile if mclock_scheduler is enabled. + CEPH_ARGS+="--osd-mclock-profile=high_recovery_ops " export margin=10 export objects=200 export poolname=test @@ -347,13 +349,13 @@ function TEST_recovery_undersized() { # Wait for recovery to finish # Can't use wait_for_clean() because state goes from active+recovering+undersized+degraded # to active+undersized+degraded - for i in $(seq 1 60) + for i in $(seq 1 300) do if ceph pg dump pgs | grep ^$PG | grep -qv recovering then break fi - if [ $i = "60" ]; + if [ $i = "300" ]; then echo "Timeout waiting for recovery to finish" return 1 diff --git a/qa/standalone/osd/osd-rep-recov-eio.sh b/qa/standalone/osd/osd-rep-recov-eio.sh index bf1adde9892d..6f871ef8fa8c 100755 --- a/qa/standalone/osd/osd-rep-recov-eio.sh +++ b/qa/standalone/osd/osd-rep-recov-eio.sh @@ -29,6 +29,7 @@ function run() { export CEPH_ARGS CEPH_ARGS+="--fsid=$(uuidgen) --auth-supported=none " CEPH_ARGS+="--mon-host=$CEPH_MON " + CEPH_ARGS+="--osd-mclock-profile=high_recovery_ops " local funcs=${@:-$(set | sed -n -e 's/^\(TEST_[0-9a-z_]*\) .*/\1/p')} @@ -301,7 +302,7 @@ function TEST_rep_backfill_unfound() { sleep 15 - for tmp in $(seq 1 100); do + for tmp in $(seq 1 360); do state=$(get_state 2.0) echo $state | grep backfill_unfound if [ "$?" = "0" ]; then diff --git a/qa/standalone/osd/repeer-on-acting-back.sh b/qa/standalone/osd/repeer-on-acting-back.sh index af406ef926b2..2a7e8a0ce4c8 100755 --- a/qa/standalone/osd/repeer-on-acting-back.sh +++ b/qa/standalone/osd/repeer-on-acting-back.sh @@ -34,6 +34,7 @@ function run() { CEPH_ARGS+="--osd_force_auth_primary_missing_objects=1000000 " # use small pg_log settings, so we always do backfill instead of recovery CEPH_ARGS+="--osd_min_pg_log_entries=$loglen --osd_max_pg_log_entries=$loglen --osd_pg_log_trim_min=$trim " + CEPH_ARGS+="--osd_mclock_profile=high_recovery_ops " local funcs=${@:-$(set | sed -n -e 's/^\(TEST_[0-9a-z_]*\) .*/\1/p')} for func in $funcs ; do