Bug 921025

Summary: [FEAT] : list directories which are in split-brain state in "gluster v heal <volume_name> info split-brain" command output
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: spandura
Component: replicateAssignee: Pranith Kumar K <pkarampu>
Status: CLOSED CURRENTRELEASE QA Contact: storage-qa-internal <storage-qa-internal>
Severity: unspecified Docs Contact:
Priority: medium    
Version: 2.0CC: ravishankar, rcyriac, rhs-bugs, storage-qa-internal, vagarwal, vbellur
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-05-20 12:00:32 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:

Description spandura 2013-03-13 10:38:04 UTC
Description of problem:
=========================
If directories are in split-brain state we are not reporting it in  "gluster v heal <volume_name> info split-brain" command output.

It will be good to report directories split-brain info


Version-Release number of selected component (if applicable):
==============================================================
[root@melman:~] Mar-13-2013 15:34:04 $ glusterfs --version
glusterfs 3.3.0.6rhs built on Mar 11 2013 04:46:21

[root@melman:~] Mar-13-2013 16:05:56 $ rpm -qa | grep gluster
glusterfs-fuse-3.3.0.6rhs-3.el6rhs.x86_64

Comment 3 Ravishankar N 2015-05-20 12:00:32 UTC
1. RHS 3.0.4 lists directories that are in split-brain:
---------------------------------------------------------
gluster v heal testvol info split-brain
Gathering list of split brain entries on volume testvol has been successful 

Brick 10.70.42.194:/brick/brick1
Number of entries: 6
at                    path on brick
-----------------------------------
2015-05-20 10:54:00 /dir
2015-05-20 11:04:00 /dir
2015-05-20 11:14:00 /dir
2015-05-20 11:24:01 /dir
2015-05-20 11:34:01 /dir
2015-05-20 11:44:01 /dir

Brick 10.70.42.194:/brick/brick2
Number of entries: 8
at                    path on brick
-----------------------------------
2015-05-20 10:44:07 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 10:44:07 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 10:54:07 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 11:04:07 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 11:14:07 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 11:24:08 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 11:34:08 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
2015-05-20 11:44:08 <gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898>
------------------------------------------------------------

2. Additionally they are also listed in the heal info command:
------------------------------------------
gluster v heal testvol info
Brick ravi3:/brick/brick1/
/dir - Is in split-brain
Number of entries: 1

Brick ravi3:/brick/brick2/
<gfid:62fd0ff6-bdfa-43ad-8909-b024b208c898> - Is in split-brain
Number of entries: 1

-----------------------------------

3. AFR xattrs on the backend:
 getfattr -d -m . -e hex  /brick/brick*/dir
getfattr: Removing leading '/' from absolute path names
# file: brick/brick1/dir
trusted.afr.testvol-client-0=0x000000000000000000000000
trusted.afr.testvol-client-1=0x000000000000000100000000
trusted.gfid=0x62fd0ff6bdfa43ad8909b024b208c898
trusted.glusterfs.dht=0x000000010000000000000000ffffffff

# file: brick/brick2/dir
trusted.afr.testvol-client-0=0x000000000000000100000000
trusted.afr.testvol-client-1=0x000000000000000000000000
trusted.gfid=0x62fd0ff6bdfa43ad8909b024b208c898
trusted.glusterfs.dht=0x000000010000000000000000ffffffff
-----------------

Hence closing the bug.