From 4a8384fe76aeef652554c48df737d3178eb0160c Mon Sep 17 00:00:00 2001 From: Krutika Dhananjay Date: Thu, 19 Feb 2015 19:35:17 +0530 Subject: cluster/afr: Do not increment healed_count if no healing was performed PROBLEM: When file modifications are happening while index heal is launched, index healer could pick up entries which appeared in indices/xattrop transiently during the course of the operations on the mount point, and do not really need any heal. This will cause index healer to keep doing index-heal in a loop as long as it finds this entry, by believing that it did successfully heal some gfids even when it didn't. FIX: afr_selfheal() now returns a 1 to indicate that it did not (need to) heal a given gfid. afr_shd_selfheal() will not increment healed_count whenever afr_selfheal() returns a 1. Change-Id: I0d97e11392a032a852e8c6508f691300ef0e5b98 BUG: 1194305 Signed-off-by: Krutika Dhananjay Reviewed-on: http://review.gluster.org/9713 Reviewed-by: Pranith Kumar Karampuri Tested-by: Pranith Kumar Karampuri Reviewed-by: Ravishankar N Tested-by: Gluster Build System --- xlators/cluster/afr/src/afr-self-heal.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'xlators/cluster/afr/src/afr-self-heal.h') diff --git a/xlators/cluster/afr/src/afr-self-heal.h b/xlators/cluster/afr/src/afr-self-heal.h index 74cc9608cf6..32be2480234 100644 --- a/xlators/cluster/afr/src/afr-self-heal.h +++ b/xlators/cluster/afr/src/afr-self-heal.h @@ -245,4 +245,7 @@ afr_selfheal_unlocked_inspect (call_frame_t *frame, xlator_t *this, gf_boolean_t *data_selfheal, gf_boolean_t *metadata_selfheal, gf_boolean_t *entry_selfheal); + +int +afr_selfheal_do (call_frame_t *frame, xlator_t *this, uuid_t gfid); #endif /* !_AFR_SELFHEAL_H */ -- cgit