summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-handler.c
diff options
context:
space:
mode:
authorSanju Rakonde <srakonde@redhat.com>2019-04-09 13:56:24 +0530
committerAtin Mukherjee <amukherj@redhat.com>2019-04-11 15:15:37 +0000
commit35dd17e222fe172866e15824e5ac9d242382178c (patch)
tree9fbbf7f74fc6fea35f9135fb4835b2a9656eb665 /xlators/mgmt/glusterd/src/glusterd-handler.c
parent4bae0b170d5b4fafe4327b8263c1895316ba3696 (diff)
glusterd: provide a way to detach failed node
When a gluster node in trusted storage pool has failed due to hardware issues, volume delete operation fails saying "Not all peers are up" and peer detach for failed node fails saying "Brick(s) with peer <peer_ip> exists in cluster". The idea here is to use either replace-brick or remove-brick command to remove all the bricks hosted by failed node and then re-attempting the peer detach. This change adds this trick in peer detach error message. fixes: bz#1697866 Change-Id: I0c58887479d31db603ad8d6535ea9d547880ccc8 Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-handler.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-handler.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c
index 58f8b4559d3..678425a19a8 100644
--- a/xlators/mgmt/glusterd/src/glusterd-handler.c
+++ b/xlators/mgmt/glusterd/src/glusterd-handler.c
@@ -3973,8 +3973,11 @@ set_deprobe_error_str(int op_ret, int op_errno, char *op_errstr, char *errstr,
case GF_DEPROBE_BRICK_EXIST:
snprintf(errstr, len,
- "Brick(s) with the peer "
- "%s exist in cluster",
+ "Peer %s hosts one or more bricks. If the peer is in "
+ "not recoverable state then use either replace-brick "
+ "or remove-brick command with force to remove all "
+ "bricks from the peer and attempt the peer detach "
+ "again.",
hostname);
break;