Skip to content

Commit

Permalink
[TEST] Troubleshooting auto_spare_002_pos
Browse files Browse the repository at this point in the history
Requires-builders: test
  • Loading branch information
loli10K committed Nov 24, 2017
1 parent b3f1924 commit b49d8e9
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 1 deletion.
4 changes: 3 additions & 1 deletion TEST
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ TEST_XFSTESTS_SKIP="yes"
#TEST_XFSTESTS_OPTIONS=""

### zfs-tests.sh
#TEST_ZFSTESTS_SKIP="yes"
TEST_ZFSTESTS_SKIP="yes"
#TEST_ZFSTESTS_DIR="/mnt/"
#TEST_ZFSTESTS_DISKS="vdb vdc vdd"
#TEST_ZFSTESTS_DISKSIZE="8G"
Expand Down Expand Up @@ -84,8 +84,10 @@ SUSE*)
Ubuntu-16.04*)
# ZFS enabled xfstests fails to build
TEST_XFSTESTS_SKIP="yes"
TEST_ZFSTESTS_SKIP="no"
;;
Ubuntu*)
TEST_ZFSTESTS_SKIP="no"
;;
*)
;;
Expand Down
1 change: 1 addition & 0 deletions tests/test-runner/include/logapi.shlib
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@ function log_pass

function log_fail
{
touch "/tmp/fail.lck"
_endlog $STF_FAIL "$@"
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ function cleanup
unload_scsi_debug
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "Testing automated auto-online FMA test"

log_onexit cleanup
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ function cleanup
unload_scsi_debug
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "Testing automated auto-replace FMA test"

log_onexit cleanup
Expand Down
2 changes: 2 additions & 0 deletions tests/zfs-tests/tests/functional/fault/auto_spare_001_pos.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ function cleanup
rm -f $VDEV_FILES $SPARE_FILE
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "Testing automated auto-spare FMA test"

log_onexit cleanup
Expand Down
8 changes: 8 additions & 0 deletions tests/zfs-tests/tests/functional/fault/auto_spare_002_pos.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,19 @@ verify_runnable "both"

function cleanup
{
if [[ -f "/tmp/fail.lck" ]]; then
ls -lh $ZED_LOG
zpool status -v
zpool events -v
cat $ZED_LOG
fi
log_must zinject -c all
destroy_pool $TESTPOOL
rm -f $VDEV_FILES $SPARE_FILE
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "Testing automated auto-spare FMA test"

log_onexit cleanup
Expand Down
2 changes: 2 additions & 0 deletions tests/zfs-tests/tests/functional/fault/auto_spare_ashift.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ function cleanup
rm -f $SAFE_DEVICE $FAIL_DEVICE
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "ZED should replace a device using the configured ashift property"
log_onexit cleanup

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ function cleanup
rm -f $DATA_DEVS $SPARE_DEVS
}

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

log_assert "ZED should be able to handle multiple faulted devices"
log_onexit cleanup

Expand Down
2 changes: 2 additions & 0 deletions tests/zfs-tests/tests/functional/fault/cleanup.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@

verify_runnable "global"

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

cleanup_devices $DISKS

zed_stop
Expand Down
2 changes: 2 additions & 0 deletions tests/zfs-tests/tests/functional/fault/setup.ksh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@

verify_runnable "global"

[[ -f "/tmp/fail.lck" ]] && log_unsupported ""

zed_setup
zed_start

Expand Down

0 comments on commit b49d8e9

Please sign in to comment.