PTLDEBUG=${PTLDEBUG:--1}
LUSTRE=${LUSTRE:-`dirname $0`/..}
+SETUP=${SETUP:-""}
+CLEANUP=${CLEANUP:-""}
. $LUSTRE/tests/test-framework.sh
init_test_env $@
. ${CONFIG:=$LUSTRE/tests/cfg/$NAME.sh}
formatall
}
-cleanup() {
- cleanupall
-}
-
-if [ "$ONLY" == "cleanup" ]; then
- cleanup
- exit
-fi
-
build_test_filter
-SETUP=${SETUP:-"setup"}
-CLEANUP=${CLEANUP:-"cleanup"}
+cleanup_and_setup_lustre
+rm -rf $DIR/${TESTSUITE}/[df][0-9]* # bug 13798 new t-f tdir staff
+rm -rf $DIR/[df][0-9]*
test_0a() {
# needs to run during initial client->OST connection
verify=$ROOT/tmp/verify-$$
dd if=/dev/urandom bs=4096 count=1280 | tee $verify > $DIR/$tfile
# invalidate cache, so that we're reading over the wire
- for i in /proc/fs/lustre/ldlm/namespaces/*-osc-*; do
- echo -n clear > $i/lru_size
- done
+ cancel_lru_locks osc
cmp $verify $DIR/$tfile &
cmppid=$!
fail ost1
run_test 7 "Fail OST before obd_destroy"
equals_msg `basename $0`: test complete, cleaning up
-$CLEANUP
+check_and_cleanup_lustre
[ -f "$TESTSUITELOG" ] && cat $TESTSUITELOG || true