[lustre-devel] [PATCH 30/42] lnet: socklnd: clarify error message on timeout
James Simmons
jsimmons at infradead.org
Mon Jan 23 15:00:43 PST 2023
From: Aurelien Degremont <degremoa at amazon.com>
When the local peer times out when writing
to another peer, prints an explicit error message
rather than a generic one. This is make it clearer
for admins and easier to debug.
Add port to help determining if this is always
the same one or not.
WC-bug-id: https://jira.whamcloud.com/browse/LU-16439
Lustre-commit: 5b06ba9d46e19b9d7 ("LU-16439 socklnd: clarify error message on timeout")
Signed-off-by: Aurelien Degremont <degremoa at amazon.com>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/49540
Reviewed-by: Chris Horn <chris.horn at hpe.com>
Reviewed-by: Cyril Bordage <cbordage at whamcloud.com>
Reviewed-by: Andreas Dilger <adilger at whamcloud.com>
Reviewed-by: Oleg Drokin <green at whamcloud.com>
Signed-off-by: James Simmons <jsimmons at infradead.org>
---
net/lnet/klnds/socklnd/socklnd_cb.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/net/lnet/klnds/socklnd/socklnd_cb.c b/net/lnet/klnds/socklnd/socklnd_cb.c
index 15fba9d7f0ac..17ea0cca9255 100644
--- a/net/lnet/klnds/socklnd/socklnd_cb.c
+++ b/net/lnet/klnds/socklnd/socklnd_cb.c
@@ -533,11 +533,15 @@ ksocknal_process_transmit(struct ksock_conn *conn, struct ksock_tx *tx)
if (!conn->ksnc_closing) {
switch (rc) {
case -ECONNRESET:
- LCONSOLE_WARN("Host %pISc reset our connection while we were sending data; it may have rebooted.\n",
- &conn->ksnc_peeraddr);
+ LCONSOLE_WARN("Host %pISc reset our connection while we were sending data; it may have rebooted: rc = %d\n",
+ &conn->ksnc_peeraddr, rc);
+ break;
+ case -ETIMEDOUT:
+ LCONSOLE_WARN("Timeout error while writing to %pISp. Closing socket: rc = %d\n",
+ &conn->ksnc_peeraddr, rc);
break;
default:
- LCONSOLE_WARN("There was an unexpected network error while writing to %pISc: %d.\n",
+ LCONSOLE_WARN("There was an unexpected network error while writing to %pISc: rc = %d\n",
&conn->ksnc_peeraddr, rc);
break;
}
--
2.27.0
More information about the lustre-devel
mailing list