Whamcloud - gitweb
LU-14701 tests: wrong get[set]_osd_param() call
[fs/lustre-release.git] / lustre / tests / sanityn.sh
index 860a4a9..ca804b6 100755 (executable)
@@ -568,15 +568,18 @@ run_test 18 "mmap sanity check ================================="
 
 test_19() { # bug3811
        local node=$(facet_active_host ost1)
+       local device="$FSNAME-OST*"
 
-       [ "x$DOM" = "xyes" ] && node=$(facet_active_host $SINGLEMDS)
+       [ "x$DOM" = "xyes" ] && node=$(facet_active_host $SINGLEMDS) &&
+               device="$FSNAME-MDT*"
 
        # check whether obdfilter is cache capable at all
-       get_osd_param $node '' read_cache_enable >/dev/null ||
+       get_osd_param $node $device read_cache_enable >/dev/null ||
                skip "not cache-capable obdfilter"
 
-       local MAX=$(get_osd_param $node '' readcache_max_filesize | head -n 1)
-       set_osd_param $node '' readcache_max_filesize 4096
+       local max=$(get_osd_param $node $device readcache_max_filesize |\
+               head -n 1)
+       set_osd_param $node $device readcache_max_filesize 4096
        dd if=/dev/urandom of=$TMP/$tfile bs=512k count=32
        local SUM=$(cksum $TMP/$tfile | cut -d" " -f 1,2)
        cp $TMP/$tfile $DIR1/$tfile
@@ -591,7 +594,7 @@ test_19() { # bug3811
                [ "$(cat $TMP/sum2)" = "$SUM" ] || \
                        error "$DIR2/$tfile $(cat $TMP/sum2) != $SUM"
        done
-       set_osd_param $node '' readcache_max_filesize $MAX
+       set_osd_param $node $device readcache_max_filesize $max
        rm $DIR1/$tfile
 }
 run_test 19 "test concurrent uncached read races ==============="