From 33c4541c63b59a982be5c4d6b06e07d357bdfd34 Mon Sep 17 00:00:00 2001 From: grev Date: Mon, 7 Apr 2008 15:02:40 +0000 Subject: [PATCH] b=15221 i=Adilger sanity test_71, recovery-small test_26 fixes renumbering test_26->test_26a FAIL_ON_ERROR initialization in cfg error, remote_mds, remote_ost fn fixes (b=14763, comment 19) --- lustre/tests/cfg/insanity-local.sh | 1 + lustre/tests/cfg/local.sh | 1 + lustre/tests/recovery-small.sh | 12 ++++++------ lustre/tests/sanity.sh | 2 +- lustre/tests/test-framework.sh | 6 +++--- 5 files changed, 12 insertions(+), 10 deletions(-) diff --git a/lustre/tests/cfg/insanity-local.sh b/lustre/tests/cfg/insanity-local.sh index 5249250..25b7bcd 100644 --- a/lustre/tests/cfg/insanity-local.sh +++ b/lustre/tests/cfg/insanity-local.sh @@ -76,4 +76,5 @@ POWER_UP=${POWER_UP:-"powerman --on"} PDSH=${PDSH:-no_dsh} SLOW=${SLOW:-no} +FAIL_ON_ERROR=${FAIL_ON_ERROR:-true} diff --git a/lustre/tests/cfg/local.sh b/lustre/tests/cfg/local.sh index 9fccbbf..740615a 100644 --- a/lustre/tests/cfg/local.sh +++ b/lustre/tests/cfg/local.sh @@ -98,3 +98,4 @@ FAILURE_MODE=${FAILURE_MODE:-SOFT} # or HARD POWER_DOWN=${POWER_DOWN:-"powerman --off"} POWER_UP=${POWER_UP:-"powerman --on"} SLOW=${SLOW:-no} +FAIL_ON_ERROR=${FAIL_ON_ERROR:-true} diff --git a/lustre/tests/recovery-small.sh b/lustre/tests/recovery-small.sh index dc797be..3b38c13 100755 --- a/lustre/tests/recovery-small.sh +++ b/lustre/tests/recovery-small.sh @@ -12,8 +12,8 @@ init_test_env $@ . ${CONFIG:=$LUSTRE/tests/cfg/$NAME.sh} # also long tests: 19, 21a, 21e, 21f, 23, 27 -# 1 2.5 4 4 (min)" -[ "$SLOW" = "no" ] && EXCEPT_SLOW="17 26b 50 51 57" +# 1 2.5 2.5 4 4 (min)" +[ "$SLOW" = "no" ] && EXCEPT_SLOW="17 26a 26b 50 51 57" build_test_filter @@ -587,10 +587,10 @@ test_24() { # bug 2248 - eviction fails writeback but app doesn't see it } run_test 24 "fsync error (should return error)" -test_26() { # bug 5921 - evict dead exports by pinger +test_26a() { # was test_26 bug 5921 - evict dead exports by pinger # this test can only run from a client on a separate node. - remote_ost || skip "local OST" && return - remote_mds || skip "local MDS" && return + remote_ost || { skip "local OST" && return 0; } + remote_mds || { skip "local MDS" && return 0; } OST_FILE=obdfilter.${ost1_svc}.num_exports OST_EXP="`do_facet ost1 lctl get_param -n $OST_FILE`" OST_NEXP1=`echo $OST_EXP | cut -d' ' -f2` @@ -609,7 +609,7 @@ test_26() { # bug 5921 - evict dead exports by pinger [ $OST_NEXP1 -le $OST_NEXP2 ] && error "client not evicted" return 0 } -run_test 26 "evict dead exports" +run_test 26a "evict dead exports" test_26b() { # bug 10140 - evict dead exports by pinger client_df diff --git a/lustre/tests/sanity.sh b/lustre/tests/sanity.sh index f4ee076..367995e 100644 --- a/lustre/tests/sanity.sh +++ b/lustre/tests/sanity.sh @@ -2990,7 +2990,7 @@ test_69() { run_test 69 "verify oa2dentry return -ENOENT doesn't LBUG ======" test_71() { - which dbench > /dev/null 2>&1 || skip "dbench not installed, skip this test" && return 0 + which dbench > /dev/null 2>&1 || { skip "dbench not installed, skip this test" && return 0; } DBENCH_LIB=${DBENCH_LIB:-/usr/lib/dbench} PATH=${DBENCH_LIB}:${PATH} cp `which dbench` $DIR diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh index 9b57846..075dfd9 100644 --- a/lustre/tests/test-framework.sh +++ b/lustre/tests/test-framework.sh @@ -1265,7 +1265,7 @@ error_noexit() { error() { error_noexit "$@" - [ "$FAIL_ON_ERROR" ] && exit 1 || true + $FAIL_ON_ERROR && exit 1 || true } error_exit() { @@ -1509,7 +1509,7 @@ osc_to_ost() remote_mds () { - [ ! -z "$(lctl dl | grep \)" ] + [ -z "$(lctl dl | grep mdt)" ] } remote_mds_nodsh() @@ -1519,7 +1519,7 @@ remote_mds_nodsh() remote_ost () { - [ -z "$(lctl dl | grep \)" ] + [ -z "$(lctl dl | grep ost)" ] } remote_ost_nodsh() -- 1.8.3.1