Bug 1233611

Summary: Incomplete conservative merge for split-brained directories
Product: [Community] GlusterFS Reporter: Ravishankar N <ravishankar>
Component: replicateAssignee: Ravishankar N <ravishankar>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.7.1CC: bugs, gluster-bugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.7.3 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1180545 Environment:
Last Closed: 2015-07-30 09:47:07 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1180545    
Bug Blocks: 1230517    

Description Ravishankar N 2015-06-19 09:33:34 UTC
+++ This bug was initially created as a clone of Bug #1180545 +++

Description of problem:
 While performing conservative merge, we bail out of the merge if we encounter a
 file with mismatching gfid or type. What this means is all entries that come
 after the mismatching file (during the merge) never get healed, no matter how
 many index heals are done.

How reproducible:
Always

Steps to Reproduce:
(1).Create 1x2 volume, fuse mount it.
(2).Bring bricks down alternatively and creates files inside directory from mount.
(3).At least one of the files must have same file name so that we have a gfid mismatch when (2) is done.
(4) Trigger index heal.

Actual results:
Conservative merge does not happen fully.

Expected results:
It must.

--- Additional comment from Anand Avati on 2015-01-09 07:21:37 EST ---

REVIEW: http://review.gluster.org/9429 (afr: complete conservative merge even in case of gfid split-brain.) posted (#1) for review on master by Ravishankar N (ravishankar)

--- Additional comment from Anand Avati on 2015-06-17 09:23:15 EDT ---

REVIEW: http://review.gluster.org/9429 (afr: complete conservative merge even in case of gfid split-brain.) posted (#2) for review on master by Ravishankar N (ravishankar)

--- Additional comment from Anand Avati on 2015-06-18 06:03:29 EDT ---

REVIEW: http://review.gluster.org/9429 (afr: complete conservative merge even in case of gfid split-brain.) posted (#3) for review on master by Ravishankar N (ravishankar)

--- Additional comment from Anand Avati on 2015-06-19 00:12:28 EDT ---

REVIEW: http://review.gluster.org/9429 (afr: complete conservative merge even in case of gfid split-brain.) posted (#4) for review on master by Ravishankar N (ravishankar)

Comment 1 Anand Avati 2015-06-19 09:38:32 UTC
REVIEW: http://review.gluster.org/11327 (afr: complete conservative merge even in case of gfid split-brain) posted (#1) for review on release-3.7 by Ravishankar N (ravishankar)

Comment 2 Anand Avati 2015-06-22 10:08:35 UTC
COMMIT: http://review.gluster.org/11327 committed in release-3.7 by Pranith Kumar Karampuri (pkarampu) 
------
commit c13e7d8cb22fb530f765359829f748b9b94103fc
Author: Ravishankar N <ravishankar>
Date:   Fri Jun 19 14:56:17 2015 +0530

    afr: complete conservative merge even in case of gfid split-brain
    
    Backport of http://review.gluster.org/#/c/9429/
    
    Problem:
    While performing conservative merge, we bail out of the merge if we
    encounter a file with mismatching gfid or type. What this means is all entries
    that come after the mismatching file (during the merge) never get healed, no
    matter how many index heals are done.
    
    Fix:
    Continue with the merging of rest of the entries even if a gfid/type mismatch
    is found, but ensure that post-op does not happen on the parent dir in such a
    case.
    
    Change-Id: I725e3ebbb8f8d692179432752c6a6554a924c597
    BUG: 1233611
    Signed-off-by: Ravishankar N <ravishankar>
    Reviewed-on: http://review.gluster.org/11327
    Reviewed-by: Krutika Dhananjay <kdhananj>
    Reviewed-by: Anuradha Talur <atalur>
    Tested-by: NetBSD Build System <jenkins.org>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Pranith Kumar Karampuri <pkarampu>

Comment 3 Kaushal 2015-07-30 09:47: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.3, please open a new bug report.

glusterfs-3.7.3 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/12078
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user