From f0bacb2a51fbb3cd6645ee94d83e0a01549852dc Mon Sep 17 00:00:00 2001 From: karthik-us Date: Mon, 10 Sep 2018 15:07:43 +0530 Subject: cli: Add warning message while converting to replica 2 configuration Currently while creating replica 2 volume we display a warning message of ending up in split-brain. But while converting an existing volume from other configuration to replica 2 by add-brick or remove-brick operations we do not show any such messages. With this fix in add-brick and remove-brick cases also we will display the same warning message and prompt for confirmation if the configuration changes to replica 2. Change-Id: Ifc4ed6994a087d2403894f4e743c4eb41633276b fixes: bz#1627044 Signed-off-by: karthik-us --- cli/src/cli.h | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'cli/src/cli.h') diff --git a/cli/src/cli.h b/cli/src/cli.h index 3421d6911f..9a392e4ec1 100644 --- a/cli/src/cli.h +++ b/cli/src/cli.h @@ -261,8 +261,8 @@ cli_cmd_get_state_parse (struct cli_state *state, const char **words, int wordcount, dict_t **options, char **op_errstr); int32_t -cli_cmd_volume_add_brick_parse (const char **words, int wordcount, - dict_t **options, int *type); +cli_cmd_volume_add_brick_parse (struct cli_state *state, const char **words, + int wordcount, dict_t **options, int *type); int32_t cli_cmd_volume_detach_tier_parse (const char **words, int wordcount, @@ -277,9 +277,10 @@ cli_cmd_volume_old_tier_parse (const char **words, int wordcount, dict_t **options); int32_t -cli_cmd_volume_remove_brick_parse (const char **words, int wordcount, - dict_t **options, int *question, - int *brick_count, int32_t *command); +cli_cmd_volume_remove_brick_parse (struct cli_state *state, const char **words, + int wordcount, dict_t **options, + int *question, int *brick_count, + int32_t *command); int32_t cli_cmd_volume_replace_brick_parse (const char **words, int wordcount, -- cgit