Whamcloud - gitweb
LU-10670 test: make sanity-flr test_43 more reliable
[fs/lustre-release.git] / lustre / tests / sanity-dom.sh
index 066a759..3126b00 100644 (file)
@@ -42,13 +42,7 @@ DOM="yes"
 DOM_SIZE=${DOM_SIZE:-"$((1024*1024))"}
 OSC="mdc"
 
-trap restore_default_layout EXIT
-restore_default_layout() {
-       [ -n "$saved_layout" ] && restore_layout $DIR1 $saved_layout ||
-               $LFS setstripe -d $DIR1
-}
-
-saved_layout=$(save_layout $DIR1)
+save_layout_restore_at_exit $DIR1
 $LFS setstripe -E $DOM_SIZE -L mdt -E EOF $DIR1
 
 mkdir -p $MOUNT2
@@ -103,7 +97,6 @@ run_test fsx "Dual-mount fsx with DoM files"
 
 test_sanity()
 {
-       [[ -f sanity.sh ]] || { skip "sanity.sh doesn't exist"; return 0; }
        # XXX: to fix 45. Add 42a, c when LU-9693 fixed.
        # Add 42b when LU-6493 fixed
        ONLY="36 39 40 41 42d 42e 43 46 56r 101e 119a 131 150 155a 155b 155c \
@@ -113,7 +106,6 @@ run_test sanity "Run sanity with Data-on-MDT files"
 
 test_sanityn()
 {
-       [[ -f sanityn.sh ]] || { skip "sanityn.sh doesn't exist"; return 0; }
        # XXX: to fix 60
        ONLY="1 2 4 5 6 7 8 9 10 11 12 14 17 19 20 23 27 39 51a 51c 51d" \
                OSC="mdc" DOM="yes" bash sanityn.sh