Bug 1221128 - `gluster volume heal <vol-name> split-brain' tries to heal even with insufficient arguments
Summary: `gluster volume heal <vol-name> split-brain' tries to heal even with insuffic...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: replicate
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Anuradha
QA Contact:
URL:
Whiteboard:
Depends On: 1218570 1223746
Blocks: qe_tracker_everglades
TreeView+ depends on / blocked
 
Reported: 2015-05-13 10:52 UTC by Anuradha
Modified: 2016-09-20 02:01 UTC (History)
5 users (show)

Fixed In Version: glusterfs-3.8rc2
Doc Type: Bug Fix
Doc Text:
Clone Of: 1218570
Environment:
Last Closed: 2016-06-16 13:00:40 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Anuradha 2015-05-13 10:52:47 UTC
+++ This bug was initially created as a clone of Bug #1218570 +++

Description of problem:
------------------------

See the following command for resolution of split-brains -

# gluster v heal <vol-name> split-brain
Usage: /usr/sbin/glfsheal <VOLNAME> [bigger-file <FILE> | source-brick <HOSTNAME:BRICKNAME> [<FILE>] | split-brain-info]
Volume heal failed.

Observe that the message displays "Volume heal failed." even though the command was run with insufficient arguments. This command should have ideally resulted in a parse error as the choice of brick or file for resolution of split-brain is not provided. Instead, it tries to heal and fails.

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

glusterfs-3.7.0alpha0-0.17.gited96153.el6.x86_64

How reproducible:
------------------

Always

Steps to Reproduce:
--------------------

1. Run the command below and observe the message displayed -

# gluster v heal <vol-name> split-brain

Actual results:
-----------------

glusterfs tries to heal the file even with insufficient arguments whereas ideally this should have resulted in a parse error.

Expected results:
------------------

Heal should not be attempted if arguments provided are incorrect or insufficient.

Additional info:

Comment 1 Anand Avati 2015-05-13 11:46:21 UTC
REVIEW: http://review.gluster.org/10771 (cli: Fix incorrect parse logic for volume heal commands) posted (#1) for review on master by Anuradha Talur (atalur)

Comment 2 Anand Avati 2015-05-28 11:04:08 UTC
REVIEW: http://review.gluster.org/10771 (cli: Fix incorrect parse logic for volume heal commands) posted (#2) for review on master by Anuradha Talur (atalur)

Comment 3 Anand Avati 2015-06-02 09:47:31 UTC
COMMIT: http://review.gluster.org/10771 committed in master by Pranith Kumar Karampuri (pkarampu) 
------
commit 59981aeb1cd02dcc534ec43ec4ec5bca5cbbd1fb
Author: Anuradha <atalur>
Date:   Wed May 13 15:29:57 2015 +0530

    cli: Fix incorrect parse logic for volume heal commands
    
    heal-op was being incorrectly set to
    GF_SHD_OP_SBRAIN_HEAL_FROM_BIGGER_FILE.
    
    Change-Id: I4d4461c7737feae30102e82f7788083017485669
    BUG: 1221128
    Signed-off-by: Anuradha <atalur>
    Reviewed-on: http://review.gluster.org/10771
    Reviewed-by: Ravishankar N <ravishankar>
    Reviewed-by: Krutika Dhananjay <kdhananj>
    Reviewed-by: Pranith Kumar Karampuri <pkarampu>
    Tested-by: NetBSD Build System <jenkins.org>

Comment 4 Niels de Vos 2016-06-16 13:00:40 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


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