From: David Zafman Date: Thu, 7 Feb 2019 23:48:48 +0000 (-0800) Subject: test: osd-backfill-stats.sh Fix check of multi backfill OSDs, skip remapped test X-Git-Tag: v14.1.0~176^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=910a95b9c8668c0563156d09aa32f2df35c6fb42;p=ceph.git test: osd-backfill-stats.sh Fix check of multi backfill OSDs, skip remapped test Signed-off-by: David Zafman --- diff --git a/qa/standalone/osd/osd-backfill-stats.sh b/qa/standalone/osd/osd-backfill-stats.sh index e38bece05804c..afa1cebaa967f 100755 --- a/qa/standalone/osd/osd-backfill-stats.sh +++ b/qa/standalone/osd/osd-backfill-stats.sh @@ -70,13 +70,17 @@ function check() { local misplaced_end=$8 local primary_start=${9:-} local primary_end=${10:-} + local check_setup=${11:-true} local log=$(grep -l +backfilling $dir/osd.$primary.log) - test -n "$log" || return 1 - if [ "$(echo "$log" | wc -w)" != "1" ]; + if [ $check_setup = "true" ]; then - echo "Test setup failure, a single OSD should have performed backfill" - return 1 + local alllogs=$(grep -l +backfilling $dir/osd.*.log) + if [ "$(echo "$alllogs" | wc -w)" != "1" ]; + then + echo "Test setup failure, a single OSD should have performed backfill" + return 1 + fi fi local addp=" " @@ -478,7 +482,7 @@ function TEST_backfill_remapped() { local misplaced=$(expr $objects \* 2) - check $dir $PG $primary replicated 0 0 $misplaced $objects || return 1 + check $dir $PG $primary replicated 0 0 $misplaced $objects "" "" false || return 1 delete_pool $poolname kill_daemons $dir || return 1