|
|
17b94a |
From e205516ef874d617e4756856098bf10e17b0ea3d Mon Sep 17 00:00:00 2001
|
|
|
17b94a |
From: Raghavendra G <rgowdapp@redhat.com>
|
|
|
17b94a |
Date: Fri, 22 Mar 2019 10:40:45 +0530
|
|
|
17b94a |
Subject: [PATCH 49/52] transport/socket: log shutdown msg occasionally
|
|
|
17b94a |
|
|
|
17b94a |
>Change-Id: If3fc0884e7e2f45de2d278b98693b7a473220a5f
|
|
|
17b94a |
>Signed-off-by: Raghavendra G <rgowdapp@redhat.com>
|
|
|
17b94a |
>Fixes: bz#1691616
|
|
|
17b94a |
|
|
|
17b94a |
BUG: 1691620
|
|
|
17b94a |
Change-Id: If3fc0884e7e2f45de2d278b98693b7a473220a5f
|
|
|
17b94a |
Signed-off-by: Sunil Kumar Acharya <sheggodu@redhat.com>
|
|
|
17b94a |
Reviewed-on: https://code.engineering.redhat.com/gerrit/167088
|
|
|
17b94a |
Tested-by: RHGS Build Bot <nigelb@redhat.com>
|
|
|
17b94a |
---
|
|
|
17b94a |
rpc/rpc-transport/socket/src/socket.c | 4 ++--
|
|
|
17b94a |
rpc/rpc-transport/socket/src/socket.h | 1 +
|
|
|
17b94a |
2 files changed, 3 insertions(+), 2 deletions(-)
|
|
|
17b94a |
|
|
|
17b94a |
diff --git a/rpc/rpc-transport/socket/src/socket.c b/rpc/rpc-transport/socket/src/socket.c
|
|
|
17b94a |
index 121d46b..f6de1d3 100644
|
|
|
17b94a |
--- a/rpc/rpc-transport/socket/src/socket.c
|
|
|
17b94a |
+++ b/rpc/rpc-transport/socket/src/socket.c
|
|
|
17b94a |
@@ -807,8 +807,8 @@ __socket_shutdown(rpc_transport_t *this)
|
|
|
17b94a |
gf_log(this->name, GF_LOG_DEBUG, "shutdown() returned %d. %s", ret,
|
|
|
17b94a |
strerror(errno));
|
|
|
17b94a |
} else {
|
|
|
17b94a |
- gf_log(this->name, GF_LOG_INFO, "intentional socket shutdown(%d)",
|
|
|
17b94a |
- priv->sock);
|
|
|
17b94a |
+ GF_LOG_OCCASIONALLY(priv->shutdown_log_ctr, this->name, GF_LOG_INFO,
|
|
|
17b94a |
+ "intentional socket shutdown(%d)", priv->sock);
|
|
|
17b94a |
}
|
|
|
17b94a |
|
|
|
17b94a |
return ret;
|
|
|
17b94a |
diff --git a/rpc/rpc-transport/socket/src/socket.h b/rpc/rpc-transport/socket/src/socket.h
|
|
|
17b94a |
index 32339d3..e1ccae2 100644
|
|
|
17b94a |
--- a/rpc/rpc-transport/socket/src/socket.h
|
|
|
17b94a |
+++ b/rpc/rpc-transport/socket/src/socket.h
|
|
|
17b94a |
@@ -219,6 +219,7 @@ typedef struct {
|
|
|
17b94a |
int keepalivecnt;
|
|
|
17b94a |
int timeout;
|
|
|
17b94a |
int log_ctr;
|
|
|
17b94a |
+ int shutdown_log_ctr;
|
|
|
17b94a |
/* ssl_error_required is used only during the SSL connection setup
|
|
|
17b94a |
* phase.
|
|
|
17b94a |
* It holds the error code returned by SSL_get_error() and is used to
|
|
|
17b94a |
--
|
|
|
17b94a |
1.8.3.1
|
|
|
17b94a |
|