summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2018-03-29 21:28:33 +0530
committerjiffin tony Thottan <jthottan@redhat.com>2018-04-06 12:50:03 +0000
commit14b7a7b63c970b735c4f7e8be9e6f31dd148c6f9 (patch)
tree805e57ff191684b8a3aa3f36a3f8a52b5d628b2d
parent3cd3e338ea4586b772d8be0e2b798e7fd36539b0 (diff)
cluster/afr: Prevent ping-event handling on shd
On shd, we shouldn't treat any brick down based on latency, otherwise self-heal will never happen fixes: 1562723 Change-Id: Ica07fcc4fae91a6bfd9c9a670e2be464704d94b7 BUG: 1562723 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
-rw-r--r--xlators/cluster/afr/src/afr-common.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c
index a83484e00d1..e52a651dbac 100644
--- a/xlators/cluster/afr/src/afr-common.c
+++ b/xlators/cluster/afr/src/afr-common.c
@@ -4883,6 +4883,8 @@ __afr_handle_ping_event (xlator_t *this, xlator_t *child_xlator,
priv->child_latency[idx] = child_latency_msec;
gf_msg_debug (child_xlator->name, 0, "Client ping @ %ld ms",
child_latency_msec);
+ if (priv->shd.iamshd)
+ return;
up_children = __afr_get_up_children_count (priv);