Whamcloud - gitweb
LU-1201 checksum: add libcfs crypto hash
[fs/lustre-release.git] / lustre / tests / sanity.sh
index f1c0519..6214363 100644 (file)
@@ -1,6 +1,4 @@
 #!/bin/bash
-# -*- mode: Bash; tab-width: 4; indent-tabs-mode: t; -*-
-# vim:autoindent:shiftwidth=4:tabstop=4:
 #
 # Run select tests by setting ONLY, or as arguments to the script.
 # Skip specific tests by setting EXCEPT.
@@ -2427,6 +2425,8 @@ test_39i() {
 run_test 39i "write, rename, stat =============================="
 
 test_39j() {
+       debugsave
+       lctl set_param debug=-1
        touch $DIR1/$tfile
        sleep 1
 
@@ -2447,6 +2447,7 @@ test_39j() {
                cancel_lru_locks osc
                if [ $i = 0 ] ; then echo "repeat after cancel_lru_locks"; fi
        done
+       debugrestore
 }
 run_test 39j "write, rename, close, stat ======================="
 
@@ -4695,7 +4696,7 @@ test_77i() { # bug 13805
        for VALUE in `lctl get_param osc.*osc-[^mM]*.checksum_type`; do
                PARAM=`echo ${VALUE[0]} | cut -d "=" -f1`
                algo=`lctl get_param -n $PARAM | sed 's/.*\[\(.*\)\].*/\1/g'`
-               [ "$algo" = "crc32" ] || error "algo set to $algo instead of crc32"
+               [ "$algo" = "adler" ] || error "algo set to $algo instead of adler"
        done
        remount_client $MOUNT
 }
@@ -8764,10 +8765,10 @@ verify_jobstats() {
 
 test_205() { # Job stats
        local cmd
-       OLD_JOBENV=`$LCTL get_param -n llite.*.jobid_var`
+       OLD_JOBENV=`$LCTL get_param -n jobid_var`
        if [ $OLD_JOBENV != $JOBENV ]; then
-               do_facet mgs $LCTL conf_param $FSNAME.llite.jobid_var=$JOBENV
-               wait_update $HOSTNAME "$LCTL get_param -n llite.*.jobid_var" \
+               do_facet mgs $LCTL conf_param $FSNAME.sys.jobid_var=$JOBENV
+               wait_update $HOSTNAME "$LCTL get_param -n jobid_var" \
                        $JOBENV || return 1
        fi
 
@@ -8806,8 +8807,8 @@ test_205() { # Job stats
        rm -f $DIR/jobstats_test_rename
 
        if [ $OLD_JOBENV != $JOBENV ]; then
-               do_facet mgs $LCTL conf_param $FSNAME.llite.jobid_var=$OLD_JOBENV
-               wait_update $HOSTNAME "$LCTL get_param -n llite.*.jobid_var" \
+               do_facet mgs $LCTL conf_param $FSNAME.sys.jobid_var=$OLD_JOBENV
+               wait_update $HOSTNAME "$LCTL get_param -n jobid_var" \
                        $OLD_JOBENV || return 1
        fi
 }
@@ -9284,6 +9285,18 @@ test_226 () {
 }
 run_test 226 "call path2fid and fid2path on files of all type"
 
+# LU-1299 Executing or running ldd on a truncated executable does not
+# cause an out-of-memory condition.
+test_227() {
+       dd if=`which date` of=$MOUNT/date bs=1k count=1
+       chmod +x $MOUNT/date
+
+       $MOUNT/date > /dev/null
+       ldd $MOUNT/date > /dev/null
+       rm -f $MOUNT/date
+}
+run_test 227 "running truncated executable does not cause OOM"
+
 #
 # tests that do cleanup/setup should be run at the end
 #