[Bugs] [Bug 1243700] GlusterD crashes when management encryption is enabled
bugzilla at redhat.com
bugzilla at redhat.com
Fri Jul 17 07:19:06 UTC 2015
https://bugzilla.redhat.com/show_bug.cgi?id=1243700
--- Comment #2 from Anand Avati <aavati at redhat.com> ---
COMMIT: http://review.gluster.org/11690 committed in release-3.6 by Raghavendra
Bhat (raghavendra at redhat.com)
------
commit 6263e73688ba2be49fd55f4c6a2d12609ce45f91
Author: Kaushal M <kaushal at redhat.com>
Date: Mon Jul 13 16:16:00 2015 +0530
rpc-transport: socket_poller fixes for proper working of mgmt encryption
Backport of 8c39f14 from master
socket_poller, the polling function used by ssl own_thread, had two
issues which lead to GlusterD crashes when using management encryption
Issue 1
-------
socket_poller calls functions which require THIS to be set. But, THIS
was being set conditionally. Because of this, functions could sometimes
be called without THIS being set. For example, rpc_transport_notify
could be called for an accepted client socket without THIS being set, as
THIS was only set it the transport wasn't yet connected. This would
cause the process to crash when THIS was accessed by the called
functions.
To fix this, THIS is being set at the start of socket_poller
unconditionally.
Issue 2
-------
DISCONNECT notify was being sent on the listener transport instead of
the client transport. The DISCONNECT event was converted to a
LISTENER_DEAD event in rpcsvc_handle_disconnect, as it could not find
the listener socket of the listener socket. GlusterD was notified of a
LISTENER_DEAD event instead of a DISCONNECT and failed to remove the
client transport from its xprt_list. The transport would subsequently
be freed, leaving the xprt_list with a corrupted/invalid entry. Later,
when GlusterD would iterate over the xprt_list to send notifications, it
would crash when the invalid entry was accessed.
To fix this, DISCONNECT notification in socket_poller is sent on the
client socket, as it is done in the epoll handler.
Change-Id: I0370b7c6d7eb13de10ebf08d91a4a39dc7d64c7a
BUG: 1243700
Signed-off-by: Kaushal M <kaushal at redhat.com>
Reviewed-on: http://review.gluster.org/11690
Tested-by: Gluster Build System <jenkins at build.gluster.com>
Reviewed-by: Raghavendra G <rgowdapp at redhat.com>
Reviewed-by: Raghavendra Bhat <raghavendra at redhat.com>
--
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=4Z2HewFoz9&a=cc_unsubscribe
More information about the Bugs
mailing list