summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorshishir gowda <shishirng@gluster.com>2010-12-23 04:08:43 +0000
committerAnand V. Avati <avati@dev.gluster.com>2010-12-29 10:20:32 -0800
commitf0eeffe7b658164fb060a9805aa6cc422aba213b (patch)
tree7f020eeca90a08d0967136fe544efc143d84fe4b
parent818a4d128048721d70be2d6c8eafd2f41034b260 (diff)
afr_lookup_done: Propogate the same inode number as sent in first lookup
If only one subvolume was up, we used to unwind, without updating the ino Signed-off-by: shishir gowda <shishirng@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 2144 (errors removing directories when one subvolume is down) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2144
-rw-r--r--xlators/cluster/afr/src/afr-common.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c
index b9f3692629f..81f01c125f8 100644
--- a/xlators/cluster/afr/src/afr-common.c
+++ b/xlators/cluster/afr/src/afr-common.c
@@ -637,13 +637,6 @@ afr_lookup_done (call_frame_t *frame, xlator_t *this, struct iatt *lookup_buf)
local->cont.lookup.buf.ia_ino = local->cont.lookup.ino;
}
- up_count = afr_up_children_count (priv->child_count, priv->child_up);
- if (up_count == 1) {
- gf_log (this->name, GF_LOG_DEBUG,
- "Only 1 child up - do not attempt to detect self heal");
- goto unwind;
- }
-
if (local->op_ret == 0) {
/* KLUDGE: assuming DHT will not itransform in
revalidate */
@@ -652,6 +645,13 @@ afr_lookup_done (call_frame_t *frame, xlator_t *this, struct iatt *lookup_buf)
local->cont.lookup.inode->ino;
}
}
+ up_count = afr_up_children_count (priv->child_count, priv->child_up);
+ if (up_count == 1) {
+ gf_log (this->name, GF_LOG_DEBUG,
+ "Only 1 child up - do not attempt to detect self heal");
+
+ goto unwind;
+ }
if (local->success_count && local->enoent_count) {
local->self_heal.need_metadata_self_heal = _gf_true;