summaryrefslogtreecommitdiffstats
path: root/xlators/features/changelog/src/changelog.c
diff options
context:
space:
mode:
authorKotresh HR <khiremat@redhat.com>2015-06-09 10:44:44 +0530
committerVenky Shankar <vshankar@redhat.com>2015-06-12 03:38:02 -0700
commite58b55ed9b2e802e6c3e908cbbad71c00f6c5b97 (patch)
tree173c3c7d5849a3e0a6da051ab36d0ecd56a7d5dc /xlators/features/changelog/src/changelog.c
parent6180d36ff30ecbe84c91b66b23734cf4f45249c5 (diff)
features/changelog: Do htime setxattr without XATTR_REPLACE flag
HTIME_KEY marks the last changelog rolled over. The xattr is maintained on .glusterfs/changelog/htime/HTIME.TSTAMP file. On every rollover of the changelog file, the xattr is updated. It is being updated with XATTR_REPLACE flag as xattr gets created during changelog enable. But it is once found that the xattrs on the file is cleared and is not reproduced later on. This patch protects that case, if it happens by setting xattr without XATTR_REPLACE flag in failure case. The reason behind doing this in failure case is not to mask the actual cause of xattrs getting cleared. This provides the log message if the original issue still exists but the consequential effects are fixed. Also changed the log messages to depict the events happened during changelog enable. Change-Id: I699ed09a03667fd823d01d65c9c360fa7bc0e455 BUG: 1230015 Signed-off-by: Kotresh HR <khiremat@redhat.com> Reviewed-on: http://review.gluster.org/11150 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Venky Shankar <vshankar@redhat.com>
Diffstat (limited to 'xlators/features/changelog/src/changelog.c')
-rw-r--r--xlators/features/changelog/src/changelog.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/xlators/features/changelog/src/changelog.c b/xlators/features/changelog/src/changelog.c
index cbad0e59dc7..fd266b598a0 100644
--- a/xlators/features/changelog/src/changelog.c
+++ b/xlators/features/changelog/src/changelog.c
@@ -2418,8 +2418,7 @@ reconfigure (xlator_t *this, dict_t *options)
if (active_now) {
if (!active_earlier) {
gf_log (this->name, GF_LOG_INFO,
- "Changelog enable: Creating new "
- "HTIME.TSTAMP file");
+ "Reconfigure: Changelog Enable");
if (gettimeofday(&tv, NULL) ) {
gf_log (this->name, GF_LOG_ERROR,
"unable to fetch htime");