From: Emoly Liu Date: Tue, 16 Apr 2013 13:24:44 +0000 (+0800) Subject: LU-3375 test: use available mdc for replay-single test_44 X-Git-Tag: 2.4.52~42 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=54f163e1f393a8b7b88b9a3961a68517c258902a LU-3375 test: use available mdc for replay-single test_44 This patch corrects that to only look for the available mdc device whose status is "UP". Test-Parameters: clientdistro=fc18 clientarch=x86_64 serverdistro=el6 serverarch=x86_64 testlist=replay-single envdefinitions=SLOW=yes Signed-off-by: Liu Ying Change-Id: Ia4013e68f44b0c1c5eb173b04af4c8c67e4961cf Reviewed-on: http://review.whamcloud.com/6425 Tested-by: Hudson Reviewed-by: Nathaniel Clark Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/replay-single.sh b/lustre/tests/replay-single.sh index ed2531d..acb02d8 100755 --- a/lustre/tests/replay-single.sh +++ b/lustre/tests/replay-single.sh @@ -908,8 +908,8 @@ run_test 43 "mds osc import failure during recovery; don't LBUG" test_44a() { # was test_44 local at_max_saved=0 - local mdcdev=$($LCTL get_param -n devices | - awk "/ ${FSNAME}-MDT0000-mdc-/ {print \$1}") + local mdcdev=$($LCTL dl | + awk "/${FSNAME}-MDT0000-mdc-/ {if (\$2 == \"UP\") {print \$1}}") [ "$mdcdev" ] || return 2 [ $(echo $mdcdev | wc -w) -eq 1 ] || { echo mdcdev=$mdcdev; $LCTL dl; return 3; } @@ -937,8 +937,8 @@ test_44a() { # was test_44 run_test 44a "race in target handle connect" test_44b() { - local mdcdev=$($LCTL get_param -n devices | - awk "/ ${FSNAME}-MDT0000-mdc-/ {print \$1}") + local mdcdev=$($LCTL dl | + awk "/${FSNAME}-MDT0000-mdc-/ {if (\$2 == \"UP\") {print \$1}}") [ "$mdcdev" ] || return 2 [ $(echo $mdcdev | wc -w) -eq 1 ] || { echo mdcdev=$mdcdev; $LCTL dl; return 3; }