From 17a69cf25ed0991e04d85c259f4294dc59734e1e Mon Sep 17 00:00:00 2001 From: Niu Yawei Date: Sun, 18 Dec 2011 22:51:26 -0800 Subject: [PATCH] LU-924 test: sync client data before reboot server Lustre doesn't write client data synchronously (to avoid flooding sync writes when there are many clients connecting, see exp_need_sync), so if the server reboots before client data reachs disk, the client data will be lost and client will be evicted after recovery, which is not what we expected. Signed-off-by: Niu Yawei Change-Id: I21bcafe1f2630285c9108c0528467eb177e3449b Reviewed-on: http://review.whamcloud.com/1888 Tested-by: Hudson Reviewed-by: Chris Gearing Reviewed-by: Jinshan Xiong Tested-by: Maloo Reviewed-by: Oleg Drokin --- lustre/tests/test-framework.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh index 06224d3..95c89d8 100644 --- a/lustre/tests/test-framework.sh +++ b/lustre/tests/test-framework.sh @@ -1517,6 +1517,14 @@ facet_failover() { echo "Failing $facet on node $host" + # Make sure the client data is synced to disk. LU-924 + # + # We don't write client data synchrnously (to avoid flooding sync writes + # when there are many clients connecting), so if the server reboots before + # the client data reachs disk, the client data will be lost and the client + # will be evicted after recovery, which is not what we expected. + do_facet $facet "sync; sync; sync" + local affected=$(affected_facets $facet) shutdown_facet $facet -- 1.8.3.1