From: Patrick Caulfield Date: Wed, 27 Jun 2007 10:36:23 +0000 (+0100) Subject: [DLM] Telnet to port 21064 can stop all lockspaces X-Git-Tag: MMI-PSA29.97-13-9~42345^2~9 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=97d848365e603def43c69e160937f073bf9cf02e;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git [DLM] Telnet to port 21064 can stop all lockspaces This patch fixes Red Hat bz#245892 Opening a tcp connection from a cluster member to another cluster member targeting the dlm port it is enough to stop every dlm operation in the cluster. This means that GFS and rgmanager will hang. Signed-Off-By: Patrick Caulfield Signed-off-by: Steven Whitehouse --- diff --git a/fs/dlm/lowcomms.c b/fs/dlm/lowcomms.c index fc0bff74c61e..73d44f57e24a 100644 --- a/fs/dlm/lowcomms.c +++ b/fs/dlm/lowcomms.c @@ -720,11 +720,17 @@ static int tcp_accept_from_sock(struct connection *con) INIT_WORK(&othercon->rwork, process_recv_sockets); set_bit(CF_IS_OTHERCON, &othercon->flags); newcon->othercon = othercon; + othercon->sock = newsock; + newsock->sk->sk_user_data = othercon; + add_sock(newsock, othercon); + addcon = othercon; + } + else { + printk("Extra connection from node %d attempted\n", nodeid); + result = -EAGAIN; + up_write(&newcon->sock_sem); + goto accept_err; } - othercon->sock = newsock; - newsock->sk->sk_user_data = othercon; - add_sock(newsock, othercon); - addcon = othercon; } else { newsock->sk->sk_user_data = newcon;