core: glusterd/add-brick-and-validate-replicated-volume-options.t is crash

Problem: Sometime brick is getting crash at the time of handling
         pmap signin request

Solution: glusterfs_mgmt_pamp_signin is using same frame to send
          pmap signin request so to avoid crash send signin request
          on separate frame

Change-Id: I443f854171ec4372e8d5f84bdc576c468e92c493
fixes: bz#1665656
Signed-off-by: Mohit Agrawal <moagrawal@redhat.com>
This commit is contained in:
Mohit Agrawal 2019-01-12 11:17:23 +05:30 committed by Amar Tumballi
parent 211521f039
commit f578cdad23

View File

@ -1736,7 +1736,6 @@ glusterfs_handle_barrier(rpcsvc_request_t *req)
goto submit_reply;
}
submit_reply:
THIS = old_THIS;
@ -2841,7 +2840,6 @@ glusterfs_mgmt_pmap_signin(glusterfs_ctx_t *ctx)
0,
};
frame = create_frame(THIS, ctx->pool);
cmd_args = &ctx->cmd_args;
if (!cmd_args->brick_port || !cmd_args->brick_name) {
@ -2865,6 +2863,7 @@ glusterfs_mgmt_pmap_signin(glusterfs_ctx_t *ctx)
if (ctx->active) {
top = ctx->active->first;
for (trav_p = &top->children; *trav_p; trav_p = &(*trav_p)->next) {
frame = create_frame(THIS, ctx->pool);
req.brick = (*trav_p)->xlator->name;
ret = mgmt_submit_request(&req, frame, ctx, &clnt_pmap_prog,
GF_PMAP_SIGNIN, mgmt_pmap_signin_cbk,
@ -2874,11 +2873,8 @@ glusterfs_mgmt_pmap_signin(glusterfs_ctx_t *ctx)
"failed to send sign in request; brick = %s", req.brick);
}
}
} else {
ret = mgmt_submit_request(&req, frame, ctx, &clnt_pmap_prog,
GF_PMAP_SIGNIN, mgmt_pmap_signin_cbk,
(xdrproc_t)xdr_pmap_signin_req);
}
/* unfortunately, the caller doesn't care about the returned value */
out: