From 9fcff8e5c6900e6792c59579a30eff92d9dfb667 Mon Sep 17 00:00:00 2001 From: rread Date: Thu, 20 Nov 2003 00:50:56 +0000 Subject: [PATCH] - during disconnect, downgrade import level early for non-replayable obds. This prevents ptlrpc from automatically reconnecting on a network failure. --- lustre/ptlrpc/import.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lustre/ptlrpc/import.c b/lustre/ptlrpc/import.c index 650b65a..80742c8 100644 --- a/lustre/ptlrpc/import.c +++ b/lustre/ptlrpc/import.c @@ -192,6 +192,12 @@ int ptlrpc_disconnect_import(struct obd_import *imp) request = ptlrpc_prep_req(imp, rq_opc, 0, NULL, NULL); if (request) { + /* For non-replayable connections, don't attempt + reconnect if this fails */ + if (!imp->imp_obd->obd_replayable) { + imp->imp_state = LUSTRE_IMP_DISCON; + request->rq_send_state = LUSTRE_IMP_DISCON; + } request->rq_replen = lustre_msg_size(0, NULL); rc = ptlrpc_queue_wait(request); ptlrpc_req_finished(request); -- 1.8.3.1