From: Alexander.Zarochentev Date: Wed, 3 Feb 2010 18:01:03 +0000 (+0300) Subject: b=21558 improve test 21b COS=0 check X-Git-Tag: 1.10.0.36~2 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;ds=sidebyside;h=981dff4a75c3f0e1e6de9ae443a694edd6cdd3b9;p=fs%2Flustre-release.git b=21558 improve test 21b COS=0 check In test 21b, when testing that the dependent renames are not replied if COS=0, there is still a window when transactions may be written to disk before the mds device is set R/O. To avoid such a rare test failure, the check is repeated several times. i=tappro i=rober.read --- diff --git a/lustre/tests/replay-dual.sh b/lustre/tests/replay-dual.sh index f450f70..e6fb1a1 100755 --- a/lustre/tests/replay-dual.sh +++ b/lustre/tests/replay-dual.sh @@ -514,8 +514,16 @@ test_21b() { COS=0 do_facet mds$num lctl set_param mdt.*.commit_on_sharing=$COS - test_21b_sub mds$num && error "Not all renames are replayed. COS=$COS" - + # there is still a window when transactions may be written to disk before + # the mds device is set R/O. To avoid such a rare test failure, the check + # is repeated several times. + local n_attempts=1 + while true; do + test_21b_sub mds$num || break; + let n_attempts=n_attempts+1 + [ $n_attemtps -gt 3] && + error "The test cannot check whether COS works or not: all renames are replied w/o COS" + done restore_lustre_params < $param_file rm -f $param_file return 0