diff options
author | hari gowtham <hgowtham@redhat.com> | 2015-09-15 14:57:24 +0530 |
---|---|---|
committer | Dan Lambright <dlambrig@redhat.com> | 2015-09-16 15:14:41 -0700 |
commit | c9d7d1e8975bad63811e32c5289a144b734c9ab2 (patch) | |
tree | 7a935d717f1522a32bec71b26df24668fc06e42c | |
parent | 2834bdf52c1ed690f74ed05fec5d28ecd05c0624 (diff) |
Tiering:Changing error message as detach-tier instead of "remove-brick"
Change-Id: Id93424a08f601a8d7540d96a47ed2b0497d4a631
BUG: 1263177
Signed-off-by: hari gowtham <hgowtham@redhat.com>
Reviewed-on: http://review.gluster.org/12177
Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Dan Lambright <dlambrig@redhat.com>
Tested-by: Dan Lambright <dlambrig@redhat.com>
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-brick-ops.c | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c index 612ab921d64..8cb2bb33f4c 100644 --- a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c +++ b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c @@ -1862,10 +1862,19 @@ glusterd_op_stage_remove_brick (dict_t *dict, char **op_errstr) } if (GLUSTERD_STATUS_STARTED != volinfo->status) { - snprintf (msg, sizeof (msg), "Volume %s needs to be " - "started before remove-brick (you can use " - "'force' or 'commit' to override this " - "behavior)", volinfo->volname); + if (volinfo->type == GF_CLUSTER_TYPE_TIER) { + snprintf (msg, sizeof (msg), "Volume %s needs " + "to be started before detach-tier " + "(you can use 'force' or 'commit' " + "to override this behavior)", + volinfo->volname); + } else { + snprintf (msg, sizeof (msg), "Volume %s needs " + "to be started before remove-brick " + "(you can use 'force' or 'commit' " + "to override this behavior)", + volinfo->volname); + } errstr = gf_strdup (msg); gf_msg (this->name, GF_LOG_ERROR, 0, GD_MSG_VOL_NOT_STARTED, "%s", errstr); |