summaryrefslogtreecommitdiff
path: root/0039-cli-fix-query-to-user-during-brick-mux-selection.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-08-01 14:35:16 +0000
committerCoprDistGit <infra@openeuler.org>2024-08-01 14:35:16 +0000
commit2453fd874197f84e11ae70053cff7f56a32988f4 (patch)
treed6ce5f0f1defa8b7a9b070ba870a8b7f916578dc /0039-cli-fix-query-to-user-during-brick-mux-selection.patch
parente47cbe682033e9df1530280ef7460c172c32961a (diff)
automatic import of glusterfsopeneuler24.03_LTS
Diffstat (limited to '0039-cli-fix-query-to-user-during-brick-mux-selection.patch')
-rw-r--r--0039-cli-fix-query-to-user-during-brick-mux-selection.patch61
1 files changed, 61 insertions, 0 deletions
diff --git a/0039-cli-fix-query-to-user-during-brick-mux-selection.patch b/0039-cli-fix-query-to-user-during-brick-mux-selection.patch
new file mode 100644
index 0000000..82684cb
--- /dev/null
+++ b/0039-cli-fix-query-to-user-during-brick-mux-selection.patch
@@ -0,0 +1,61 @@
+From ec707e099d4e4338d1ea21560d367b02e6339532 Mon Sep 17 00:00:00 2001
+From: Sunil Kumar Acharya <sheggodu@redhat.com>
+Date: Mon, 1 Apr 2019 16:16:47 +0530
+Subject: [PATCH 39/52] cli: fix query to user during brick-mux selection
+
+Label: DOWNSTREAM ONLY
+
+Change-Id: I59472066b917ea2b23de72bcd91dc3e275d5e055
+Signed-off-by: Sunil Kumar Acharya <sheggodu@redhat.com>
+---
+ cli/src/cli-cmd-parser.c | 33 +++++++++++++++++----------------
+ 1 file changed, 17 insertions(+), 16 deletions(-)
+
+diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c
+index 541dc62..d9ccba1 100644
+--- a/cli/src/cli-cmd-parser.c
++++ b/cli/src/cli-cmd-parser.c
+@@ -1693,23 +1693,24 @@ cli_cmd_volume_set_parse(struct cli_state *state, const char **words,
+ goto out;
+ }
+ }
+- }
+-
+- if ((strcmp (key, "cluster.brick-multiplex") == 0)) {
+- question = "Brick-multiplexing is supported only for "
+- "OCS converged or independent mode. Also it is "
+- "advised to make sure that either all "
+- "volumes are in stopped state or no bricks "
+- "are running before this option is modified."
+- "Do you still want to continue?";
+
+- answer = cli_cmd_get_confirmation (state, question);
+- if (GF_ANSWER_NO == answer) {
+- gf_log ("cli", GF_LOG_ERROR, "Operation "
+- "cancelled, exiting");
+- *op_errstr = gf_strdup ("Aborted by user.");
+- ret = -1;
+- goto out;
++ if ((strcmp (key, "cluster.brick-multiplex") == 0)) {
++ question =
++ "Brick-multiplexing is supported only for "
++ "OCS converged or independent mode. Also it is "
++ "advised to make sure that either all "
++ "volumes are in stopped state or no bricks "
++ "are running before this option is modified."
++ "Do you still want to continue?";
++
++ answer = cli_cmd_get_confirmation (state, question);
++ if (GF_ANSWER_NO == answer) {
++ gf_log ("cli", GF_LOG_ERROR, "Operation "
++ "cancelled, exiting");
++ *op_errstr = gf_strdup ("Aborted by user.");
++ ret = -1;
++ goto out;
++ }
+ }
+ }
+
+--
+1.8.3.1
+