From: James Nunez Date: Fri, 10 May 2013 14:15:50 +0000 (-0600) Subject: LU-3304 tests: sanity-quota test_18 watchdog triggered X-Git-Tag: 2.4.52~46 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=462dda94432b0179835ac7f8e2eabb0ccc83adcc LU-3304 tests: sanity-quota test_18 watchdog triggered sanity-quota test_18 is picking up watchdog messages from prevous tests. The fix is clearing dmesg at the beginning of test_18. This also allowed us to remove some of strings that the awk command looking for, i.e. the subtest name. Test-Parameters: envdefinitions=SLOW=yes,ENABLE_QUOTA=yes \ testlist=sanity-quota Signed-off-by: James Nunez Change-Id: I9a20bd2e374048f252219038df3590fef339a672 Reviewed-on: http://review.whamcloud.com/6310 Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Niu Yawei Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/sanity-quota.sh b/lustre/tests/sanity-quota.sh index 13e5373..a2cef17 100644 --- a/lustre/tests/sanity-quota.sh +++ b/lustre/tests/sanity-quota.sh @@ -1707,17 +1707,17 @@ test_18_sub () { # test when mds does failover, the ost still could work well # this test shouldn't trigger watchdog b=14840 test_18() { + # Clear dmesg so watchdog is not triggered by previous + # test output + do_facet ost1 dmesg -c > /dev/null + test_18_sub normal test_18_sub directio # check if watchdog is triggered do_facet ost1 dmesg > $TMP/lustre-log-${TESTNAME}.log - local watchdog=$(awk '/sanity-quota test 18/ {start = 1;} - /Service thread pid/ && /was inactive/ { - if (start) { - print; - } - }' $TMP/lustre-log-${TESTNAME}.log) + local watchdog=$(awk '/Service thread pid/ && /was inactive/ \ + { print; }' $TMP/lustre-log-${TESTNAME}.log) [ -z "$watchdog" ] || error "$watchdog" rm -f $TMP/lustre-log-${TESTNAME}.log }