From f9d1ac5ab499b0b9a31a957da35455515e567c49 Mon Sep 17 00:00:00 2001 From: wangdi Date: Fri, 14 Sep 2012 07:39:21 -0700 Subject: [PATCH] LU-1944 ldlm: Add another net_latency to recoverry timer. Add another net_latency to this request deadline, i.e. we need add 2 net_latency to extend the recovery timer, one for balance rq_deadline (see ptl_send_rpc), one for resend the req to server. Signed-off-by: Wang Di Change-Id: I6cb6e57358f4fe32ae2ac8d982af6ce03b68014b Reviewed-on: http://review.whamcloud.com/4351 Tested-by: Hudson Tested-by: Maloo Reviewed-by: Andreas Dilger Reviewed-by: Jinshan Xiong Reviewed-by: Oleg Drokin --- lustre/ldlm/ldlm_lib.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lustre/ldlm/ldlm_lib.c b/lustre/ldlm/ldlm_lib.c index bba19e9..a7ada1b 100644 --- a/lustre/ldlm/ldlm_lib.c +++ b/lustre/ldlm/ldlm_lib.c @@ -1958,8 +1958,11 @@ static int handle_recovery_req(struct ptlrpc_thread *thread, to = max((int)at_est2timeout( at_get(&svcpt->scp_at_estimate)), (int)lustre_msg_get_timeout(req->rq_reqmsg)); - /* Add net_latency (see ptlrpc_replay_req) */ - to += lustre_msg_get_service_time(req->rq_reqmsg); + /* Add 2 net_latency, one for balance rq_deadline + * (see ptl_send_rpc), one for resend the req to server, + * Note: client will pack net_latency in replay req + * (see ptlrpc_replay_req) */ + to += 2 * lustre_msg_get_service_time(req->rq_reqmsg); } extend_recovery_timer(class_exp2obd(req->rq_export), to, true); } -- 1.8.3.1