|
|
d1681e |
From 1eb5f1a725cc9afdd7b1a7b29cf446b9c60974c6 Mon Sep 17 00:00:00 2001
|
|
|
d1681e |
From: Mohit Agrawal <moagrawa@redhat.com>
|
|
|
d1681e |
Date: Tue, 8 May 2018 14:52:04 +0530
|
|
|
d1681e |
Subject: [PATCH 260/260] dht: Avoid dict log flooding for internal MDS xattr
|
|
|
d1681e |
|
|
|
d1681e |
Problem: Before populate MDS internal xattr first dht checks if MDS is
|
|
|
d1681e |
present in xattr or not.If xattr dictionary is NULL dict_get
|
|
|
d1681e |
log the message either dict or key is NULL
|
|
|
d1681e |
|
|
|
d1681e |
Solution: Before call dict_get check xattr, if it is NULL then no
|
|
|
d1681e |
need to call dict_get.
|
|
|
d1681e |
|
|
|
d1681e |
> BUG: 1575910
|
|
|
d1681e |
> Change-Id: I81604ec5945b85eba14b42f4583d06ec713028f4
|
|
|
d1681e |
> fixes: bz#1575910
|
|
|
d1681e |
> (cherry picked from commit ed5a09e4aea7f64f9a43698955e24285a936f0c0)
|
|
|
d1681e |
> (Upstream link https://review.gluster.org/#/c/19981/)
|
|
|
d1681e |
|
|
|
d1681e |
BUG: 1575895
|
|
|
d1681e |
Change-Id: I728a8068786f94d3793a91cdd5c64f813d7545ca
|
|
|
d1681e |
Signed-off-by: Mohit Agrawal <moagrawa@redhat.com>
|
|
|
d1681e |
Reviewed-on: https://code.engineering.redhat.com/gerrit/138205
|
|
|
d1681e |
Tested-by: RHGS Build Bot <nigelb@redhat.com>
|
|
|
d1681e |
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
|
|
|
d1681e |
---
|
|
|
d1681e |
xlators/cluster/dht/src/dht-common.c | 2 +-
|
|
|
d1681e |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
d1681e |
|
|
|
d1681e |
diff --git a/xlators/cluster/dht/src/dht-common.c b/xlators/cluster/dht/src/dht-common.c
|
|
|
d1681e |
index 3b8ba6d..a985481 100644
|
|
|
d1681e |
--- a/xlators/cluster/dht/src/dht-common.c
|
|
|
d1681e |
+++ b/xlators/cluster/dht/src/dht-common.c
|
|
|
d1681e |
@@ -855,7 +855,7 @@ dht_common_mark_mdsxattr (call_frame_t *frame, int *errst, int mark_during_fresh
|
|
|
d1681e |
and wind a setxattr call on hashed subvol to update
|
|
|
d1681e |
internal xattr
|
|
|
d1681e |
*/
|
|
|
d1681e |
- if (!dict_get (local->xattr, conf->mds_xattr_key)) {
|
|
|
d1681e |
+ if (!local->xattr || !dict_get (local->xattr, conf->mds_xattr_key)) {
|
|
|
d1681e |
/* It means no internal MDS xattr has been set yet
|
|
|
d1681e |
*/
|
|
|
d1681e |
/* Check the status of all subvol are up while call
|
|
|
d1681e |
--
|
|
|
d1681e |
1.8.3.1
|
|
|
d1681e |
|