diff options
author | Krutika Dhananjay <kdhananj@redhat.com> | 2014-10-22 04:18:59 +0530 |
---|---|---|
committer | Niels de Vos <ndevos@redhat.com> | 2014-10-27 08:47:49 -0700 |
commit | a539b29c1c28dff78fa2314deafd2948f5f8ae1a (patch) | |
tree | c81a7eaf89a72a32d8a8832b1cb318c0d9322eeb | |
parent | 5fff385333db750561ffd026af09e52a8c8c16e6 (diff) |
cluster/afr: Fix excessive logging in glfsheal log file
Wrong afr_local_t instance was being used in the missing entry sh
check in afr_self_heal(), which was leading to entrylk failure messages
of the following kind in glfsheal logfile:
[2014-10-21 12:39:04.109875] I
[afr-self-heal-common.c:2146:afr_sh_post_nb_entrylk_missing_entry_sh_cbk]
0-vol-replicate-1: Non blocking entrylks failed
The fix involves sending the right "local" to
afr_can_start_missing_entry_gfid_self_heal().
After fixing this, there were two more codepaths giving out too many log messages
of the following kinds:
[2014-10-21 22:19:29.568533] E [afr-self-heal-data.c:1611:afr_sh_data_open_cbk]
0-dis-rep-replicate-1: open of 8a858b02-0fc7-4713-9f61-8ca28dea82c0
failed on child dis-rep-client-2 (Stale file handle)
[2014-10-21 22:19:29.577948] E [afr-self-heal-entry.c:2353:afr_sh_post_nonblocking_entry_cbk]
0-dis-rep-replicate-1: Non Blocking entrylks failed for ff9c82c4-5c0c-4ed9-b745-604a28dc352d.
which are also fixed appropriately as part of this patch.
Change-Id: Idd8d8e5735ee7a4ac36f369525f96e53276e0859
BUG: 1153629
Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
Reviewed-on: http://review.gluster.org/8965
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
-rw-r--r-- | xlators/cluster/afr/src/afr-self-heal-common.c | 2 | ||||
-rw-r--r-- | xlators/cluster/afr/src/afr-self-heal-data.c | 3 | ||||
-rw-r--r-- | xlators/cluster/afr/src/afr-self-heal-entry.c | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/xlators/cluster/afr/src/afr-self-heal-common.c b/xlators/cluster/afr/src/afr-self-heal-common.c index dee596a58bb..6a748aeccc6 100644 --- a/xlators/cluster/afr/src/afr-self-heal-common.c +++ b/xlators/cluster/afr/src/afr-self-heal-common.c @@ -2479,7 +2479,7 @@ afr_self_heal (call_frame_t *frame, xlator_t *this, inode_t *inode) sh->sh_type_in_action = AFR_SELF_HEAL_INVALID; FRAME_SU_DO (sh_frame, afr_local_t); - if (afr_can_start_missing_entry_gfid_self_heal (local, priv)) { + if (afr_can_start_missing_entry_gfid_self_heal (sh_local, priv)) { afr_self_heal_missing_entries (sh_frame, this); } else { loc = &sh_local->loc; diff --git a/xlators/cluster/afr/src/afr-self-heal-data.c b/xlators/cluster/afr/src/afr-self-heal-data.c index 08983e66f20..343f9c193ad 100644 --- a/xlators/cluster/afr/src/afr-self-heal-data.c +++ b/xlators/cluster/afr/src/afr-self-heal-data.c @@ -1604,7 +1604,8 @@ afr_sh_data_open_cbk (call_frame_t *frame, void *cookie, xlator_t *this, LOCK (&frame->lock); { if (op_ret == -1) { - gf_log (this->name, GF_LOG_ERROR, + gf_log (this->name, + fop_log_level (GF_FOP_OPEN, op_errno), "open of %s failed on child %s (%s)", local->loc.path, priv->children[child_index]->name, diff --git a/xlators/cluster/afr/src/afr-self-heal-entry.c b/xlators/cluster/afr/src/afr-self-heal-entry.c index f816e493075..5db11bb72fe 100644 --- a/xlators/cluster/afr/src/afr-self-heal-entry.c +++ b/xlators/cluster/afr/src/afr-self-heal-entry.c @@ -2349,7 +2349,7 @@ afr_sh_post_nonblocking_entry_cbk (call_frame_t *frame, xlator_t *this) sh = &local->self_heal; if (int_lock->lock_op_ret < 0) { - gf_log (this->name, GF_LOG_ERROR, "Non Blocking entrylks " + gf_log (this->name, GF_LOG_DEBUG, "Non Blocking entrylks " "failed for %s.", local->loc.path); afr_set_self_heal_status (sh, AFR_SELF_HEAL_FAILED); afr_sh_entry_done (frame, this); |