diff options
author | Mohammed Rafi KC <rkavunga@redhat.com> | 2014-09-18 04:21:04 -0400 |
---|---|---|
committer | Raghavendra Bhat <raghavendra@redhat.com> | 2015-01-06 01:39:15 -0800 |
commit | bb1601b94039b27b5a148479b61895a100ce8e6d (patch) | |
tree | e0ec227bdf0c487855958ce9d8bf61bc41ab54d1 /rpc | |
parent | 707ef16edcf4b14f46bb515b3464fa4368ce9b7c (diff) |
rdma:rdma fuse mount hangs for tcp,rdma volumes if brick is down.
Backport of http://review.gluster.org/8762
When we try to mount a tcp,rdma volume as rdma
transport using FUSE protocol, then mount will
hang if the brick is down. When we kill a process,
signal will be received in glusterfsd process and
it will call pmap_signout with port listening on tcp only.
In case of the tcp,rdma there will be two ports,
and port which is listening for rdma will not
called for sign out.
So the mount process will try to connect to a port
which is not open and it will keep trying to connect.
This patch will call pmap_signout for rdma port also,
So when mount tries to get the brick port,it will fail.
Change-Id: I73f90d7340afa3b0b1278924206f1488e4094a62
BUG: 1166515
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Reviewed-on: http://review.gluster.org/8762
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Tested-by: Raghavendra G <rgowdapp@redhat.com>
Reviewed-on: http://review.gluster.org/9176
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Diffstat (limited to 'rpc')
-rw-r--r-- | rpc/rpc-transport/rdma/src/rdma.c | 7 | ||||
-rw-r--r-- | rpc/xdr/src/portmap-xdr.x | 1 |
2 files changed, 3 insertions, 5 deletions
diff --git a/rpc/rpc-transport/rdma/src/rdma.c b/rpc/rpc-transport/rdma/src/rdma.c index 3ceb197f2a3..89ed4558d72 100644 --- a/rpc/rpc-transport/rdma/src/rdma.c +++ b/rpc/rpc-transport/rdma/src/rdma.c @@ -938,7 +938,7 @@ static void gf_rdma_cm_handle_disconnect (rpc_transport_t *this) { gf_rdma_private_t *priv = NULL; - char need_unref = 0, connected = 0; + char need_unref = 0; priv = this->private; gf_log (this->name, GF_LOG_DEBUG, @@ -948,7 +948,6 @@ gf_rdma_cm_handle_disconnect (rpc_transport_t *this) { if (priv->peer.cm_id != NULL) { need_unref = 1; - connected = priv->connected; priv->connected = 0; } @@ -956,9 +955,7 @@ gf_rdma_cm_handle_disconnect (rpc_transport_t *this) } pthread_mutex_unlock (&priv->write_mutex); - if (connected) { - rpc_transport_notify (this, RPC_TRANSPORT_DISCONNECT, this); - } + rpc_transport_notify (this, RPC_TRANSPORT_DISCONNECT, this); if (need_unref) rpc_transport_unref (this); diff --git a/rpc/xdr/src/portmap-xdr.x b/rpc/xdr/src/portmap-xdr.x index f60dcc76c8e..7380de5e9ca 100644 --- a/rpc/xdr/src/portmap-xdr.x +++ b/rpc/xdr/src/portmap-xdr.x @@ -47,6 +47,7 @@ struct pmap_signin_rsp { struct pmap_signout_req { string brick<>; int port; + int rdma_port; }; struct pmap_signout_rsp { |