summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-utils.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-utils.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c
index 0a89535211f..f8434a7bdc9 100644
--- a/xlators/mgmt/glusterd/src/glusterd-utils.c
+++ b/xlators/mgmt/glusterd/src/glusterd-utils.c
@@ -2137,14 +2137,16 @@ glusterd_volume_stop_glusterfs (glusterd_volinfo_t *volinfo,
ret = 0;
}
- if (del_brick)
- glusterd_delete_brick (volinfo, brickinfo);
-
GLUSTERD_GET_BRICK_PIDFILE (pidfile, volinfo, brickinfo, conf);
gf_msg_debug (this->name, 0, "Unlinking pidfile %s", pidfile);
(void) sys_unlink (pidfile);
brickinfo->started_here = _gf_false;
+ brickinfo->status = GF_BRICK_STOPPED;
+
+ if (del_brick)
+ glusterd_delete_brick (volinfo, brickinfo);
+
out:
return ret;
}