Bug 764322 (GLUSTER-2590) - Two-part rebalance is unusable
Summary: Two-part rebalance is unusable
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: GLUSTER-2590
Product: GlusterFS
Classification: Community
Component: cli
Version: 3.1.3
Hardware: x86_64
OS: Linux
medium
high
Target Milestone: ---
Assignee: Amar Tumballi
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-03-25 18:40 UTC by Vikas Gorur
Modified: 2013-12-19 00:06 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Vikas Gorur 2011-03-25 18:40:23 UTC
[root@vikas-sb build]# /usr/sbin/gluster volume rebalance gl2 fix-layout status
Usage: volume rebalance <VOLNAME> [fix-layout|migrate-data] {start|stop|status}

The old way of invoking still works:

[root@vikas-sb build]# /usr/sbin/gluster volume rebalance gl2 status
rebalance completed

The culprit code is in cli/src/cli-cmd-volume.c: cli_cmd_volume_defrag_cbk:

if (strcmp (words[3], "start") && strcmp (words[3], "stop") && 
            strcmp (words[3], "status")) {
                cli_usage_out (word->pattern);
                parse_error = 1;
                goto out;
        }

words[3] is supposed to be [fix-layout|migrate-data]. The code is still checking for "start", "stop", and "status", and exiting.

Comment 1 Amar Tumballi 2011-03-26 02:12:07 UTC
Patch committed for this.

http://patches.gluster.com/patch/6496/


Once we have 3.2.0 ready, we will migrate it back to 3.1.x branch.

Regards,
Amar

Comment 2 Amar Tumballi 2011-04-07 00:05:16 UTC
http://patches.gluster.com/patch/6649/

fixes bug in release-3.1 branch.. committed.

Comment 3 Raghavendra Bhat 2011-04-13 07:52:34 UTC
Checked with the below commands and it worked fine.

gluster volume add-brick mirror bigbang:/d/glusterfs/export/export1 bigbang:/e/glusterfs/export/export1
Add Brick successful
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout start
starting rebalance on volume mirror has been successful
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout status
rebalance step 1: layout fix in progress
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout status
rebalance step 1: layout fix in progress: fixed layout 1
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout status
rebalance step 1: layout fix complete: fixed layout 1
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout status
rebalance step 1: layout fix complete: fixed layout 1
root@bigbang:/mnt/client# gluster volume rebalance mirror fix-layout status
rebalance step 1: layout fix complete: fixed layout 1
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data start
starting rebalance on volume mirror has been successful
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 1: layout fix in progress
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 1: layout fix in progress
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 1: layout fix in progress
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 2: data migration in progress: rebalanced 2 files of size 20480 (total files scanned 5)
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 2: data migration complete: rebalanced 54 files of size 552960 (total files scanned 154)
root@bigbang:/mnt/client# gluster volume rebalance mirror migrate-data status
rebalance step 2: data migration complete: rebalanced 54 files of size 552960 (total files scanned 154)


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