From: Nathaniel Clark Date: Thu, 1 Jun 2017 12:00:01 +0000 (-0400) Subject: LU-2189 tests: Ensure quiescence for sanityn/36 X-Git-Tag: 2.10.0-RC1~32 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=a7e534ce58efe3c5eb79250414ad5b05dfc8a13a LU-2189 tests: Ensure quiescence for sanityn/36 Because sanityn/36 measures space used/free, ensure that all previous operations have completed prior to getting statfs info. Test-Parameters: mdtfilesystemtype=zfs ostfilesystemtype=zfs osscount=1 ostcount=2 mdscount=1 mdtcount=1 testlist=sanityn Test-Parameters: mdtfilesystemtype=zfs ostfilesystemtype=zfs osscount=1 ostcount=2 mdscount=1 mdtcount=1 testlist=sanityn Signed-off-by: Nathaniel Clark Change-Id: I684d428bbb6fca1a004bba5acf6a17a1636fb0dd Reviewed-on: https://review.whamcloud.com/27373 Tested-by: Jenkins Reviewed-by: Bob Glossman Reviewed-by: Emoly Liu Tested-by: Maloo Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/sanityn.sh b/lustre/tests/sanityn.sh index 95027ea..74ae81e 100755 --- a/lustre/tests/sanityn.sh +++ b/lustre/tests/sanityn.sh @@ -33,8 +33,8 @@ init_test_env $@ init_logging if [ $(facet_fstype $SINGLEMDS) = "zfs" ]; then -# bug number for skipped test: LU-2189 LU-2776 - ALWAYS_EXCEPT="$ALWAYS_EXCEPT 36 51a" +# bug number for skipped test: LU-2776 + ALWAYS_EXCEPT="$ALWAYS_EXCEPT 51a" # LU-2829 / LU-2887 - make allowances for ZFS slowness TEST33_NFILES=${TEST33_NFILES:-1000} fi @@ -1213,10 +1213,12 @@ test_36() { #bug 16417 i=0 SIZE=50 let SIZE_B=SIZE*1024*1024 - sync; sleep 5; sync # wait for delete thread + sync; sleep 2; sync # wait for delete thread + wait_mds_ost_sync || error "wait_mds_ost_sync failed" + wait_destroy_complete || error "wait_destroy_complete failed" while [ $i -le 10 ]; do - lctl mark "start test" + lctl mark "start test - cycle ($i)" local before=$(lfs_df $MOUNT1 | awk '/^filesystem/{ print $4; exit }') dd if=/dev/zero of=$DIR1/$tdir/$tfile bs=1M count=$SIZE || error "dd $DIR1/$tdir/$tfile ${SIZE}MB failed" @@ -1229,6 +1231,7 @@ test_36() { #bug 16417 rm -f $DIR1/$tdir/$tfile kill -USR1 $read_pid wait $read_pid + sync; sleep 2; sync # Ensure new statfs wait_delete_completed local after=$(lfs_df $MOUNT1 | awk '/^filesystem/{ print $4; exit }') echo "*** cycle($i) *** before($before) after_dd($after_dd)" \