summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr-inode-write.c
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2016-01-08 13:06:27 +0530
committerVijay Bellur <vbellur@redhat.com>2016-01-27 19:21:15 -0800
commiteca923349b4cb397b19520e4e391e42b8d6532c2 (patch)
tree31936f38075cf29bfa1b495b4f6c095ad219367d /xlators/cluster/afr/src/afr-inode-write.c
parentd57bf5bf59c72ef5c791efed885b5f2d80e42a97 (diff)
cluster/afr: Move remaining gf_logs to gf_msgs
Change-Id: I48d9e5313bd3ccf9fe26c90a7051a8a174d75c49 BUG: 1296818 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/13195 Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com> Smoke: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/cluster/afr/src/afr-inode-write.c')
-rw-r--r--xlators/cluster/afr/src/afr-inode-write.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/xlators/cluster/afr/src/afr-inode-write.c b/xlators/cluster/afr/src/afr-inode-write.c
index 297d7b8b0dd..6b9d5ee87b0 100644
--- a/xlators/cluster/afr/src/afr-inode-write.c
+++ b/xlators/cluster/afr/src/afr-inode-write.c
@@ -1111,7 +1111,8 @@ _afr_handle_replace_brick_type (xlator_t *this, call_frame_t *frame,
}
if (!count) {
- gf_log (this->name, GF_LOG_ERROR, "Couldn't acquire lock on"
+ gf_msg (this->name, GF_LOG_ERROR, EAGAIN,
+ AFR_MSG_REPLACE_BRICK_STATUS, "Couldn't acquire lock on"
" any child.");
ret = -EAGAIN;
goto unlock;
@@ -1169,8 +1170,8 @@ _afr_handle_replace_brick (void *opaque)
loc_copy (&local->loc, &data->loc);
- gf_log (this->name, GF_LOG_DEBUG, "Child being replaced is : %s",
- priv->children[rb_index]->name);
+ gf_msg_debug (this->name, 0, "Child being replaced is : %s",
+ priv->children[rb_index]->name);
ret = _afr_handle_replace_brick_type (this, frame, &local->loc, rb_index,
AFR_METADATA_TRANSACTION);
@@ -1420,9 +1421,10 @@ afr_handle_replace_brick (xlator_t *this, call_frame_t *frame, loc_t *loc,
if (!ret) {
if (frame->root->pid != GF_CLIENT_PID_SELF_HEALD) {
- gf_log (this->name, GF_LOG_ERROR, "'%s' is an internal"
- " extended attribute : %s.",
- GF_AFR_REPLACE_BRICK, strerror (EPERM));
+ gf_msg (this->name, GF_LOG_ERROR, EPERM,
+ AFR_MSG_REPLACE_BRICK_STATUS, "'%s' is an "
+ "internal extended attribute",
+ GF_AFR_REPLACE_BRICK);
ret = 1;
goto out;
}