summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKotresh HR <khiremat@redhat.com>2015-04-28 18:09:29 +0530
committerVijay Bellur <vbellur@redhat.com>2015-05-04 02:29:19 -0700
commit02223349a0a141d5bd09edcd571a703bb2e5a94d (patch)
tree3dc5060f5ff8ecf1d6d668d29d2305e7bc2deeb1
parent20353cc323704292753ea6b7b0034362109fef76 (diff)
downloadglusterfs-02223349a0a141d5bd09edcd571a703bb2e5a94d.tar.gz
glusterfs-02223349a0a141d5bd09edcd571a703bb2e5a94d.tar.xz
glusterfs-02223349a0a141d5bd09edcd571a703bb2e5a94d.zip
geo-rep: Fix ignoring geo-rep safe errors
Fix ignoring geo-rep safe errors in fuse layer and also ignore logging in client translator for mknod. Though it is rare, to happen with mknod, it might happen with history crawl on overlapping changelogs replay. Change-Id: I7e145cd1dc53f04d444ad2e68e66e648be448e61 BUG: 1210562 Signed-off-by: Kotresh HR <khiremat@redhat.com> Reviewed-on: http://review.gluster.org/10422 Tested-by: NetBSD Build System Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Aravinda VK <avishwan@redhat.com>
-rw-r--r--xlators/mount/fuse/src/fuse-bridge.c16
-rw-r--r--xlators/protocol/client/src/client-rpc-fops.c3
2 files changed, 11 insertions, 8 deletions
diff --git a/xlators/mount/fuse/src/fuse-bridge.c b/xlators/mount/fuse/src/fuse-bridge.c
index 683146288e..871059d569 100644
--- a/xlators/mount/fuse/src/fuse-bridge.c
+++ b/xlators/mount/fuse/src/fuse-bridge.c
@@ -1253,13 +1253,15 @@ fuse_err_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
state->loc.path ? state->loc.path : "ERR");
send_fuse_err (this, finh, 0);
- } else if (GF_IGNORE_IF_GSYNCD_SAFE_ERROR(frame, op_errno)) {
- gf_log ("glusterfs-fuse", GF_LOG_WARNING,
- "%"PRIu64": %s() %s => -1 (%s)",
- frame->root->unique,
- gf_fop_list[frame->root->op],
- state->loc.path ? state->loc.path : "ERR",
- strerror (op_errno));
+ } else {
+ if (GF_IGNORE_IF_GSYNCD_SAFE_ERROR(frame, op_errno)) {
+ gf_log ("glusterfs-fuse", GF_LOG_WARNING,
+ "%"PRIu64": %s() %s => -1 (%s)",
+ frame->root->unique,
+ gf_fop_list[frame->root->op],
+ state->loc.path ? state->loc.path : "ERR",
+ strerror (op_errno));
+ }
send_fuse_err (this, finh, op_errno);
}
diff --git a/xlators/protocol/client/src/client-rpc-fops.c b/xlators/protocol/client/src/client-rpc-fops.c
index 55e8d47adc..d6ff0e9734 100644
--- a/xlators/protocol/client/src/client-rpc-fops.c
+++ b/xlators/protocol/client/src/client-rpc-fops.c
@@ -233,7 +233,8 @@ client3_3_mknod_cbk (struct rpc_req *req, struct iovec *iov, int count,
rsp.op_errno, out);
out:
- if (rsp.op_ret == -1) {
+ if (rsp.op_ret == -1 &&
+ GF_IGNORE_IF_GSYNCD_SAFE_ERROR(frame, rsp.op_errno)) {
gf_log (this->name, GF_LOG_WARNING,
"remote operation failed: %s. Path: %s",
strerror (gf_error_to_errno (rsp.op_errno)),