Whamcloud - gitweb
LU-8413 test: limit # of processes for sanity test_101f 39/23039/3
authorBobi Jam <bobijam.xu@intel.com>
Mon, 10 Oct 2016 05:44:27 +0000 (13:44 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 20 Oct 2016 10:41:26 +0000 (10:41 +0000)
It tries to test mmap readahead does not miss too much pages,
so we need limit the number of processes of the iozone read.

Test-Parameters: trivial
Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: Ic5c753549234fe2bffcaa42f75208c2295f84ac0
Reviewed-on: http://review.whamcloud.com/23039
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/sanity.sh

index 53684a0..3ff73da 100755 (executable)
@@ -6725,6 +6725,7 @@ test_101f() {
        which iozone || { skip "no iozone installed" && return; }
 
        local old_debug=$($LCTL get_param debug)
+       old_debug=${old_debug#*=}
        $LCTL set_param debug="reada mmap"
 
        # create a test file
@@ -6737,14 +6738,15 @@ test_101f() {
        $LCTL set_param -n llite.*.read_ahead_stats 0
 
        echo mmap read the file with small block size
-       iozone -i 1 -+n -r 32k -s 128m -B -f $DIR/$tfile > /dev/null 2>&1
+       iozone -i 1 -u 1 -l 1 -+n -r 32k -s 128m -B -f $DIR/$tfile \
+               > /dev/null 2>&1
 
        echo checking missing pages
        $LCTL get_param llite.*.read_ahead_stats
        local miss=$($LCTL get_param -n llite.*.read_ahead_stats |
                        get_named_value 'misses' | cut -d" " -f1 | calc_total)
 
-       $LCTL set_param debug=$old_debug
+       $LCTL set_param debug="$old_debug"
        [ $miss -lt 3 ] || error "misses too much pages ('$miss')!"
        rm -f $DIR/$tfile
 }