From 1d97e06da0225d2097335ae4cdf933f909683bac Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Tue, 3 Jul 2018 14:14:59 +0530 Subject: glusterd: show brick online after port registration even in brick-mux Problem: With brick-mux even before brick attach is complete on the bricks glusterd marks them as online. This can lead to a race where scripts that check if the bricks are online to assume that the brick is online before it is completely online. Fix: Wait for the callback from the brick before marking the port as registered so that volume status will show the correct status of the brick. fixes bz#1597568 Change-Id: Icd3dc62506af0cf75195e96746695db823312051 Signed-off-by: Pranith Kumar K --- xlators/mgmt/glusterd/src/glusterd-utils.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'xlators/mgmt/glusterd/src/glusterd-utils.h') diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.h b/xlators/mgmt/glusterd/src/glusterd-utils.h index b1209728b67..51e7c43d781 100644 --- a/xlators/mgmt/glusterd/src/glusterd-utils.h +++ b/xlators/mgmt/glusterd/src/glusterd-utils.h @@ -199,7 +199,8 @@ glusterd_volume_stop_glusterfs (glusterd_volinfo_t *volinfo, gf_boolean_t del_brick); int -send_attach_req (xlator_t *this, struct rpc_clnt *rpc, char *path, int op); +send_attach_req (xlator_t *this, struct rpc_clnt *rpc, char *path, + glusterd_brickinfo_t *brick, int op); glusterd_volinfo_t * glusterd_volinfo_ref (glusterd_volinfo_t *volinfo); -- cgit