summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libglusterfs/src/common-utils.c4
-rw-r--r--xlators/protocol/client/src/client-rpc-fops.c6
-rw-r--r--xlators/protocol/server/src/server-rpc-fops.c4
3 files changed, 10 insertions, 4 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c
index fc4ae123916..4bcef6ae33f 100644
--- a/libglusterfs/src/common-utils.c
+++ b/libglusterfs/src/common-utils.c
@@ -3669,6 +3669,10 @@ fop_log_level (glusterfs_fop_t fop, int op_errno)
return GF_LOG_DEBUG;
}
+ if (fop == GF_FOP_MKNOD || fop == GF_FOP_MKDIR)
+ if (op_errno == EEXIST)
+ return GF_LOG_DEBUG;
+
return GF_LOG_ERROR;
}
diff --git a/xlators/protocol/client/src/client-rpc-fops.c b/xlators/protocol/client/src/client-rpc-fops.c
index d6ff0e97346..d4021f53dd5 100644
--- a/xlators/protocol/client/src/client-rpc-fops.c
+++ b/xlators/protocol/client/src/client-rpc-fops.c
@@ -235,7 +235,8 @@ client3_3_mknod_cbk (struct rpc_req *req, struct iovec *iov, int count,
out:
if (rsp.op_ret == -1 &&
GF_IGNORE_IF_GSYNCD_SAFE_ERROR(frame, rsp.op_errno)) {
- gf_log (this->name, GF_LOG_WARNING,
+ gf_log (this->name, fop_log_level (GF_FOP_MKNOD,
+ gf_error_to_errno (rsp.op_errno)),
"remote operation failed: %s. Path: %s",
strerror (gf_error_to_errno (rsp.op_errno)),
local->loc.path);
@@ -302,7 +303,8 @@ client3_3_mkdir_cbk (struct rpc_req *req, struct iovec *iov, int count,
out:
if (rsp.op_ret == -1 &&
GF_IGNORE_IF_GSYNCD_SAFE_ERROR(frame, rsp.op_errno)) {
- gf_log (this->name, GF_LOG_WARNING,
+ gf_log (this->name, fop_log_level (GF_FOP_MKDIR,
+ gf_error_to_errno (rsp.op_errno)),
"remote operation failed: %s. Path: %s",
strerror (gf_error_to_errno (rsp.op_errno)),
local->loc.path);
diff --git a/xlators/protocol/server/src/server-rpc-fops.c b/xlators/protocol/server/src/server-rpc-fops.c
index c69b17fd255..df5811659a8 100644
--- a/xlators/protocol/server/src/server-rpc-fops.c
+++ b/xlators/protocol/server/src/server-rpc-fops.c
@@ -468,7 +468,7 @@ server_mkdir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
state = CALL_STATE (frame);
if (op_ret < 0) {
- gf_log (this->name, GF_LOG_INFO,
+ gf_log (this->name, fop_log_level (GF_FOP_MKDIR, op_errno),
"%"PRId64": MKDIR %s (%s/%s) ==> (%s)",
frame->root->unique, state->loc.path,
uuid_utoa (state->resolve.pargfid),
@@ -515,7 +515,7 @@ server_mknod_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
state = CALL_STATE (frame);
if (op_ret < 0) {
- gf_log (this->name, GF_LOG_INFO,
+ gf_log (this->name, fop_log_level (GF_FOP_MKNOD, op_errno),
"%"PRId64": MKNOD %s (%s/%s) ==> (%s)",
frame->root->unique, state->loc.path,
uuid_utoa (state->resolve.pargfid),