e3c68b
From 039a3f81209706261fc809eac94564e81a3377da Mon Sep 17 00:00:00 2001
e3c68b
From: Sanju Rakonde <srakonde@redhat.com>
e3c68b
Date: Wed, 25 Sep 2019 14:55:19 +0530
e3c68b
Subject: [PATCH 300/302] cli: remove the warning displayed when remove brick
e3c68b
 start issued
e3c68b
e3c68b
remove-brick start command gives displays below error:
e3c68b
e3c68b
It is recommended that remove-brick be run with cluster.force-migration
e3c68b
option disabled to prevent possible data corruption. Doing so will ensure
e3c68b
that files that receive writes during migration will not be migrated and
e3c68b
will need to be manually copied after the remove-brick commit operation.
e3c68b
Please check the value of the option and update accordingly.
e3c68b
Do you want to continue with your current cluster.force-migration settings? (y/n)
e3c68b
e3c68b
As we are not qualifying cluster.force-migration for 3.5.0,
e3c68b
we should not display this message. So, removing it.
e3c68b
e3c68b
Label: DOWNSTREAM ONLY
e3c68b
e3c68b
BUG: 1755227
e3c68b
Change-Id: I409f2059d43c5e867788f19d2ccb8d6d839520f7
e3c68b
fixes: bz#1755227
e3c68b
Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
e3c68b
Reviewed-on: https://code.engineering.redhat.com/gerrit/182009
e3c68b
Tested-by: RHGS Build Bot <nigelb@redhat.com>
e3c68b
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
e3c68b
---
e3c68b
 cli/src/cli-cmd-parser.c |  2 --
e3c68b
 cli/src/cli-cmd-volume.c | 11 -----------
e3c68b
 2 files changed, 13 deletions(-)
e3c68b
e3c68b
diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c
e3c68b
index 92ceb8e..4456a7b 100644
e3c68b
--- a/cli/src/cli-cmd-parser.c
e3c68b
+++ b/cli/src/cli-cmd-parser.c
e3c68b
@@ -2101,8 +2101,6 @@ cli_cmd_volume_remove_brick_parse(struct cli_state *state, const char **words,
e3c68b
         wordcount--;
e3c68b
         if (!strcmp("start", w)) {
e3c68b
             command = GF_OP_CMD_START;
e3c68b
-            if (question)
e3c68b
-                *question = 1;
e3c68b
         } else if (!strcmp("commit", w)) {
e3c68b
             command = GF_OP_CMD_COMMIT;
e3c68b
         } else if (!strcmp("stop", w)) {
e3c68b
diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c
e3c68b
index a42e663..6b958bd 100644
e3c68b
--- a/cli/src/cli-cmd-volume.c
e3c68b
+++ b/cli/src/cli-cmd-volume.c
e3c68b
@@ -2088,17 +2088,6 @@ cli_cmd_volume_remove_brick_cbk(struct cli_state *state,
e3c68b
             "Remove-brick force will not migrate files from the "
e3c68b
             "removed bricks, so they will no longer be available"
e3c68b
             " on the volume.\nDo you want to continue?";
e3c68b
-    } else if (command == GF_OP_CMD_START) {
e3c68b
-        question =
e3c68b
-            "It is recommended that remove-brick be run with"
e3c68b
-            " cluster.force-migration option disabled to prevent"
e3c68b
-            " possible data corruption. Doing so will ensure that"
e3c68b
-            " files that receive writes during migration will not"
e3c68b
-            " be migrated and will need to be manually copied"
e3c68b
-            " after the remove-brick commit operation. Please"
e3c68b
-            " check the value of the option and update accordingly."
e3c68b
-            " \nDo you want to continue with your current"
e3c68b
-            " cluster.force-migration settings?";
e3c68b
     }
e3c68b
 
e3c68b
     if (!brick_count) {
e3c68b
-- 
e3c68b
1.8.3.1
e3c68b