Whamcloud - gitweb
LU-7144 tests: skip scrub/lfsck test under interoperation
[fs/lustre-release.git] / lustre / tests / sanity-scrub.sh
index 18280a7..8e91ad4 100644 (file)
@@ -21,6 +21,22 @@ init_logging
 
 require_dsh_mds || exit 0
 
+load_modules
+
+if ! check_versions; then
+       skip "It is NOT necessary to test scrub under interoperation mode"
+       exit 0
+fi
+
+[ $(facet_fstype $SINGLEMDS) != "ldiskfs" ] &&
+       skip "test OI scrub only for ldiskfs" && exit 0
+
+[ $(facet_fstype ost1) != "ldiskfs" ] &&
+       skip "test OI scrub only for ldiskfs" && exit 0
+
+[[ $(lustre_version_code $SINGLEMDS) -lt $(version_code 2.2.90) ]] &&
+       skip "Need MDS version at least 2.2.90" && exit 0
+
 SAVED_MDSSIZE=${MDSSIZE}
 SAVED_OSTSIZE=${OSTSIZE}
 SAVED_OSTCOUNT=${OSTCOUNT}
@@ -39,16 +55,6 @@ MOUNT_2=""
 formatall
 setupall
 
-[ $(facet_fstype $SINGLEMDS) != "ldiskfs" ] &&
-       skip "test OI scrub only for ldiskfs" && check_and_cleanup_lustre &&
-       exit 0
-[ $(facet_fstype ost1) != "ldiskfs" ] &&
-       skip "test OI scrub only for ldiskfs" && check_and_cleanup_lustre &&
-       exit 0
-[[ $(lustre_version_code $SINGLEMDS) -lt $(version_code 2.2.90) ]] &&
-       skip "Need MDS version at least 2.2.90" && check_and_cleanup_lustre &&
-       exit 0
-
 [[ $(lustre_version_code $SINGLEMDS) -lt $(version_code 2.3.90) ]] &&
        ALWAYS_EXCEPT="$ALWAYS_EXCEPT 1a"