[Gluster-devel] split brain: how should it be cured?

Pranith Kumar Karampuri pkarampu at redhat.com
Wed Jun 20 12:25:59 UTC 2012


hi,
   Replicate only keeps track of the fact that an operation is performed successfully on one brick while on the other brick it was not successful. It does not know the actual change. So you can endup where both the files are same but there is xattr-split-brain.
Example:

touch f
bring brick-0 down
echo 'a' > f
brick brick-0 up, bring brick-1 down (assume self-heal on this file was not trggered on this file)
echo 'a' > f
Bring brick-1 up. Now the file 'f' is in xattr split-brain, even though both of the files contain same data.

Pranith.
----- Original Message -----
From: "Emmanuel Dreyfus" <manu at netbsd.org>
To: "Pranith Kumar Karampuri" <pkarampu at redhat.com>
Cc: gluster-devel at nongnu.org
Sent: Wednesday, June 20, 2012 5:03:36 PM
Subject: Re: [Gluster-devel] split brain: how should it be cured?

On Wed, Jun 20, 2012 at 05:35:36AM -0400, Pranith Kumar Karampuri wrote:
> Procedure to reset split-brain is to remove one of the files. 
> 3.3 release onwards we need to also delete the file from gfid-backend.
> if the file is a.txt with gfid 5c71a049-a424-480e-9e69-2cdfd7a0a7a0
> remove the file a.txt
> remove the file <brick-path>/.glusterfs/5c/71/5c71a049-a424-480e-9e69-2cdfd7a0a7a0
> the gfid path is a hardlink to a.txt

glusterfs 3.3 behavior is really odd. It was possible to read the
offending file, and after a while, it started  returning EIO again.
Removing the file and its gfid hardlink seems to workaround the
problem, though.

But I still do not understand how they are considered in metadata split brain: 
all metadata were the same:

On brick1:
  File: "/export/wd3a/manu/netbsd/usr/src/tools/mktemp/Makefile"
  Size: 165          FileType: Regular File
  Mode: (0644/-rw-r--r--)         Uid: (  500/    manu)  Gid: (  500/    manu)
Device: 0,16   Inode: 55748693    Links: 2
Access: Wed Jun 20 13:24:31 2012
Modify: Sun Dec  8 21:20:03 2002
Change: Wed Jun 20 11:31:28 2012

trusted.afr.pfs-client-0 00 00 00 00 00 00 00 00 00 00 00 00
trusted.afr.pfs-client-1 00 00 00 00 00 00 00 01 00 00 00 00

On brick2:
  File: "/export/wd3a/manu/netbsd/usr/src/tools/mktemp/Makefile"
  Size: 165          FileType: Regular File
  Mode: (0644/-rw-r--r--)         Uid: (  500/    manu)  Gid: (  500/    manu)
Device: 0,24   Inode: 25441937    Links: 2
Access: Wed Jun 20 13:24:31 2012
Modify: Sun Dec  8 21:20:03 2002
Change: Wed Jun 20 11:31:28 2012

trusted.afr.pfs-client-0 00 00 00 00 00 00 00 03 00 00 00 00
trusted.afr.pfs-client-1 00 00 00 00 00 00 00 00 00 00 00 00
-- 
Emmanuel Dreyfus
manu at netbsd.org

_______________________________________________
Gluster-devel mailing list
Gluster-devel at nongnu.org
https://lists.nongnu.org/mailman/listinfo/gluster-devel




More information about the Gluster-devel mailing list