Whamcloud - gitweb
LU-3664 test: get_param atime_diff returns multiple values 50/7750/3
authorJames Nunez <james.a.nunez@intel.com>
Tue, 24 Sep 2013 20:29:57 +0000 (14:29 -0600)
committerOleg Drokin <oleg.drokin@intel.com>
Fri, 27 Sep 2013 15:32:38 +0000 (15:32 +0000)
In sanityn test 23, lctl get_param mdd.*. time_diff can
return multiple values. This can happen with there are multiple
MDTs mounted. In order to deal with multiple values, we run the
return value of lctl get_param through "head -1".

Test-Parameters: mdtcount=2 mdscount=2
Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: Ie830429af38e1e4bce084aa1e6490bbadf366920
Reviewed-on: http://review.whamcloud.com/7750
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
lustre/tests/sanityn.sh

index 21f56fa..1170b2d 100644 (file)
@@ -489,7 +489,8 @@ test_21() { # Bug 5907
 run_test 21 " Try to remove mountpoint on another dir ===="
 
 test_23() { # Bug 5972
 run_test 21 " Try to remove mountpoint on another dir ===="
 
 test_23() { # Bug 5972
-       local at_diff=$(do_facet $SINGLEMDS $LCTL get_param -n mdd.*.atime_diff)
+       local at_diff=$(do_facet $SINGLEMDS \
+               $LCTL get_param -n mdd.*MDT0000*.atime_diff | head -1)
        echo "atime should be updated while another read" > $DIR1/$tfile
 
        # clear the lock(mode: LCK_PW) gotten from creating operation
        echo "atime should be updated while another read" > $DIR1/$tfile
 
        # clear the lock(mode: LCK_PW) gotten from creating operation