From c770722983f73aa838b5985755999050c746550a Mon Sep 17 00:00:00 2001 From: Amar Tumballi Date: Tue, 11 Oct 2011 16:33:24 +0530 Subject: changing of the volume types after volume is created. with this patch, one can do all the below operations: on a simple distribute volume 'test' with bricks A,B, add bricks C and D: bash# gluster volume add-brick test replica 2 C D now the volume 'test' becomes distribute-replicate, with pairs A-C, B-D. same holds good for stripe. and now, one can change the replica count 2 on volume 'test' to 4 like below: bash# gluster volume add-brick test replica 4 E F G H now, volume has 'replica' count 4, with pairs being 'A-C-E-F' and 'B-D-G-H'. after this, if user wants to reduce the replica count, he can do bash# gluster volume remove-brick test replica 3 C H # (one from each pair) This should work to reduce the replica count Change-Id: I4f109141a9ba7be4a92a5f5810a4163baeb92973 BUG: 3305 Reviewed-on: http://review.gluster.com/158 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- cli/src/cli-cmd-volume.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cli/src/cli-cmd-volume.c') diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c index 425840f7fae..36e4c659c87 100644 --- a/cli/src/cli-cmd-volume.c +++ b/cli/src/cli-cmd-volume.c @@ -1601,11 +1601,11 @@ struct cli_cmd volume_cmds[] = { cli_cmd_volume_rename_cbk, "rename volume to "},*/ - { "volume add-brick ...", + { "volume add-brick [ ] ...", cli_cmd_volume_add_brick_cbk, "add brick to volume "}, - { "volume remove-brick ... {start|pause|abort|status|commit|force}", + { "volume remove-brick [replica ] ... {start|pause|abort|status|commit|force}", cli_cmd_volume_remove_brick_cbk, "remove brick from volume "}, -- cgit