Bug 1180545

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: mainlineCC: bugs, gluster-bugs
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.8rc2 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1230517 1233611 (view as bug list) Environment:
Last Closed: 2016-06-16 12:41:05 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:    
Bug Blocks: 1230517, 1233611    

Description Ravishankar N 2015-01-09 12:18:20 UTC
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.

Comment 1 Anand Avati 2015-01-09 12:21:37 UTC
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)

Comment 2 Anand Avati 2015-06-17 13:23:15 UTC
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)

Comment 3 Anand Avati 2015-06-18 10:03:29 UTC
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)

Comment 4 Anand Avati 2015-06-19 04:12:28 UTC
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 5 Anand Avati 2015-06-22 08:42:34 UTC
COMMIT: http://review.gluster.org/9429 committed in master by Pranith Kumar Karampuri (pkarampu) 
------
commit 41805d75e47f2ce9f71d99e556885db008948fb2
Author: Ravishankar N <ravishankar>
Date:   Fri Jan 9 08:17:19 2015 +0530

    afr: complete conservative merge even in case of gfid split-brain.
    
    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: I9bbfccc8906007daa53a0750ddd401dcf83943f8
    BUG: 1180545
    Signed-off-by: Ravishankar N <ravishankar>
    Reviewed-on: http://review.gluster.org/9429
    Reviewed-by: Anuradha Talur <atalur>
    Reviewed-by: Pranith Kumar Karampuri <pkarampu>
    Tested-by: Pranith Kumar Karampuri <pkarampu>

Comment 6 Nagaprasad Sathyanarayana 2015-10-25 14:46:58 UTC
Fix for this BZ is already present in a GlusterFS release. You can find clone of this BZ, fixed in a GlusterFS release and closed. Hence closing this mainline BZ as well.

Comment 7 Niels de Vos 2016-06-16 12:41: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.8.0, please open a new bug report.

glusterfs-3.8.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://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user