Bug 1125843 - geo-rep: changelog_register fails when geo-rep started after session creation.
Summary: geo-rep: changelog_register fails when geo-rep started after session creation.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: geo-replication
Version: mainline
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
Assignee: Kotresh HR
QA Contact:
URL:
Whiteboard:
Depends On: 1125818
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-01 08:45 UTC by Kotresh HR
Modified: 2015-05-14 17:35 UTC (History)
8 users (show)

Fixed In Version: glusterfs-3.7.0beta1
Doc Type: Bug Fix
Doc Text:
Clone Of: 1125818
Environment:
Last Closed: 2015-05-14 17:26:05 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Kotresh HR 2014-08-01 08:45:44 UTC
+++ This bug was initially created as a clone of Bug #1125818 +++

Description of problem:
changelog_register fails with ENOENT when geo-rep started just after session creation. It goes to Hybrid Crawl and never goes to changelog mode untill a stop and start of geo-rep.

Version-Release number of selected component (if applicable):


How reproducible:
Happens everytime.

Steps to Reproduce:
1. Create geo-rep session between master and slave
2. Start the geo-rep between master and slave
3. Check the log to see changelog_register failure or status to see "Hybrid Crawl"

Actual results:
changelog_register fails and always be in xsync mode

Expected results:
changelog_register should not fail, it should got to history, xsync and then changelog.

Additional info:

Comment 1 Kotresh HR 2014-08-01 08:51:08 UTC
Cause: 
gf_changelog_register is failing with ENOENT for the working directory when it
tries to get the realpath.
Earlier, xsync was being called first, which creates working drectory
and changelog_register is called. Now it is history first, hence the 
issue.

Solution:
Create working directory in gf_changelog_register if its not already
created.

Comment 2 Anand Avati 2014-08-01 08:57:29 UTC
REVIEW: http://review.gluster.org/8399 (geo-rep/changelog: Create working dir during changelog_register if not present.) posted (#1) for review on master by Kotresh HR (khiremat@redhat.com)

Comment 3 Anand Avati 2014-08-01 10:47:02 UTC
REVIEW: http://review.gluster.org/8399 (geo-rep/libgfchangelog: Create working dir during changelog_register if not present.) posted (#2) for review on master by Kotresh HR (khiremat@redhat.com)

Comment 4 Anand Avati 2014-08-02 00:24:04 UTC
COMMIT: http://review.gluster.org/8399 committed in master by Vijay Bellur (vbellur@redhat.com) 
------
commit d09f69e76f86e727ea9a3487f57a0d7fd7b5bcd7
Author: Kotresh H R <khiremat@redhat.com>
Date:   Fri Aug 1 14:08:56 2014 +0530

    geo-rep/libgfchangelog: Create working dir during changelog_register if not present.
    
    Earlier, xysnc's register was being called first,
    which was creating working directory before calling
    changelog_register. Now it is history crawl first.
    Hence working directory would not have been created.
    Create it in gf_changelog_register itself if it is
    not already created.
    
    Change-Id: Ief3f2b87deaf5da16c135b64be1be42e0a7647f3
    BUG: 1125843
    Signed-off-by: Kotresh H R <khiremat@redhat.com>
    Reviewed-on: http://review.gluster.org/8399
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Reviewed-by: Aravinda VK <avishwan@redhat.com>
    Reviewed-by: Vijay Bellur <vbellur@redhat.com>

Comment 5 Kotresh HR 2014-08-04 10:07:16 UTC
A small change required to support symlinks while creating working directory
hence a rework.

Comment 6 Anand Avati 2014-08-04 10:07:53 UTC
REVIEW: http://review.gluster.org/8409 (geo-rep/libgfchangelog: Support of symlinks while creation of working dir.) posted (#1) for review on master by Kotresh HR (khiremat@redhat.com)

Comment 7 Anand Avati 2014-08-04 11:38:36 UTC
COMMIT: http://review.gluster.org/8409 committed in master by Venky Shankar (vshankar@redhat.com) 
------
commit 51394183e94ac0be70fcf22793b2040ba3f0b918
Author: Kotresh H R <khiremat@redhat.com>
Date:   Mon Aug 4 15:33:02 2014 +0530

    geo-rep/libgfchangelog: Support of symlinks while creation of working dir.
    
    In gf_changelog_register, enable symlink support while creating
    working directory if its not already created.
    
    Change-Id: I4b81762d04f5276a65087d2ff94f2a36dc504b58
    BUG: 1125843
    Signed-off-by: Kotresh H R <khiremat@redhat.com>
    Reviewed-on: http://review.gluster.org/8409
    Reviewed-by: Venky Shankar <vshankar@redhat.com>
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Tested-by: Venky Shankar <vshankar@redhat.com>

Comment 8 Niels de Vos 2015-05-14 17:26:05 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.7.0, please open a new bug report.

glusterfs-3.7.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://thread.gmane.org/gmane.comp.file-systems.gluster.devel/10939
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user

Comment 9 Niels de Vos 2015-05-14 17:28:07 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.7.0, please open a new bug report.

glusterfs-3.7.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://thread.gmane.org/gmane.comp.file-systems.gluster.devel/10939
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user

Comment 10 Niels de Vos 2015-05-14 17:35:13 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.7.0, please open a new bug report.

glusterfs-3.7.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://thread.gmane.org/gmane.comp.file-systems.gluster.devel/10939
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user


Note You need to log in before you can comment on or make changes to this bug.