summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorBasavanagowda Kanur <gowda@gluster.com>2009-04-02 06:07:25 +0530
committerAnand V. Avati <avati@amp.gluster.com>2009-04-02 18:09:28 +0530
commit705c7c9bacafc22b714ac15e3925cb5eaeb45b0a (patch)
treef59024de61cb55476789fef5a5faddf79b3f50ad /xlators
parente8cce0bed6e5e6bd926ee465c5ec7a00b0b37793 (diff)
cluster/{dht,nufa} propogate ESTALE (when at least one subvolume returns ESTALE for revalidate) to parent translator.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/cluster/dht/src/dht-common.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/xlators/cluster/dht/src/dht-common.c b/xlators/cluster/dht/src/dht-common.c
index b96db22cbca..41daac677d2 100644
--- a/xlators/cluster/dht/src/dht-common.c
+++ b/xlators/cluster/dht/src/dht-common.c
@@ -207,11 +207,20 @@ dht_revalidate_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret == -1) {
local->op_errno = op_errno;
- if (op_errno != ENOTCONN && op_errno != ENOENT) {
+ if ((op_errno != ENOTCONN)
+ && (op_errno != ENOENT)
+ && (op_errno != ESTALE)) {
gf_log (this->name, GF_LOG_WARNING,
"subvolume %s returned -1 (%s)",
prev->this->name, strerror (op_errno));
}
+
+ if (op_errno == ESTALE) {
+ /* propogate the ESTALE to parent.
+ * setting local->layout_mismatch would send
+ * ESTALE to parent. */
+ local->layout_mismatch = 1;
+ }
goto unlock;
}