assert_env ost_HOST OST_MKFS_OPTS OSTCOUNT
assert_env LIVE_CLIENT FSNAME
+remote_mds_nodsh && skip "remote MDS with nodsh" && exit 0
+remote_ost_nodsh && skip "remote OST with nodsh" && exit 0
+
# FAIL_CLIENTS list should not contain the LIVE_CLIENT
FAIL_CLIENTS=$(echo " $FAIL_CLIENTS " | sed -re "s/\s+$LIVE_CLIENT\s+/ /g")
echo "fail $FAIL_CLIENT, next is $FAIL_NEXT"
}
-shutdown_client() {
- client=$1
- if [ "$FAILURE_MODE" = HARD ]; then
- $POWER_DOWN $client
- while ping -w 3 -c 1 $client > /dev/null 2>&1; do
- echo "waiting for node $client to fail"
- sleep 1
- done
- elif [ "$FAILURE_MODE" = SOFT ]; then
- zconf_umount $client $MOUNT -f
- fi
-}
-
-reboot_node() {
- NODE=$1
- if [ "$FAILURE_MODE" = HARD ]; then
- $POWER_UP $NODE
- fi
-}
-
fail_clients() {
num=$1
echo "down clients: $DOWN_CLIENTS"
for client in $DOWN_CLIENTS; do
- reboot_node $client
+ boot_node $client
done
DOWN_NUM=`echo $DOWN_CLIENTS | wc -w`
client_rmdirs
# do_node $CLIENTS "$LCTL "'--device %OSC_`hostname`_'"${facet}_svc_MNT_client_facet recover"
}
-cleanup_and_setup_lustre
+check_and_setup_lustre
# 9 Different Failure Modes Combinations
echo "Starting Test 17 at `date`"
equals_msg `basename $0`: test complete, cleaning up
check_and_cleanup_lustre
-[ -f "$TESTSUITELOG" ] && cat $TESTSUITELOG || true
+[ -f "$TESTSUITELOG" ] && cat $TESTSUITELOG && grep -q FAIL $TESTSUITELOG && exit 1 || true