From: Eric Dumazet <eric.dumazet@gmail.com>
To: Vijay Subramanian <subramanian.vijay@gmail.com>
Cc: enh <enh@google.com>,
Venkat Venkatsubra <venkat.x.venkatsubra@oracle.com>,
netdev@vger.kernel.org
Subject: Re: listen(2) backlog changes in or around Linux 3.1?
Date: Mon, 22 Oct 2012 22:08:39 +0200 [thread overview]
Message-ID: <1350936519.8609.1239.camel@edumazet-glaptop> (raw)
In-Reply-To: <alpine.DEB.2.00.1210221251520.1684@cleese>
On Mon, 2012-10-22 at 13:00 -0700, Vijay Subramanian wrote:
> >
> > If we send a SYNACK, then receive the ACK from client, and the acceptq
> > is full, we should reset the connexion. Right now we have kind of stupid
> > situation, were we drop the ACK, and leave the REQ in the SYN_RECV
> > state, so we retransmit SYNACKS.
> >
>
>
> It seems the third ack is remembered in inet_rsk(req)->acked in
> tcp_check_req(). However, because of the order in which the tests are performed,
> server stills retransmits the synack needlessly. Following patch
> (for review) prevents this synack retransmission if third ack has been
> received.
>
> The request_sock will expire in around 30 seconds and will be dropped if it does
> not move into accept_queue by then. Maybe we should also call
> req->rsk_ops->send_reset(sk,skb);
> when the request_sock expires and is dropped?
>
Not sure its needed, and we are under stress.
>
> net/ipv4/inet_connection_sock.c | 5 ++---
> 1 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/net/ipv4/inet_connection_sock.c b/net/ipv4/inet_connection_sock.c
> index d34ce29..4e8e52e 100644
> --- a/net/ipv4/inet_connection_sock.c
> +++ b/net/ipv4/inet_connection_sock.c
> @@ -598,9 +598,8 @@ void inet_csk_reqsk_queue_prune(struct sock *parent,
> &expire, &resend);
> req->rsk_ops->syn_ack_timeout(parent, req);
> if (!expire &&
> - (!resend ||
> - !req->rsk_ops->rtx_syn_ack(parent, req, NULL) ||
> - inet_rsk(req)->acked)) {
> + (!resend || inet_rsk(req)->acked ||
> + !req->rsk_ops->rtx_syn_ack(parent, req, NULL))) {
> unsigned long timeo;
>
> if (req->retrans++ == 0)
I wonder then if we dont need to retransmit the synack when req moves
into accept_queue then ?
Or else how the client can 'knows' it can send data to server ?
All these facilities sound very complex and not really usable by clients
(ie users not willing to wait more than few seconds anyway)
next prev parent reply other threads:[~2012-10-22 20:08 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-12 23:40 listen(2) backlog changes in or around Linux 3.1? enh
2012-10-15 17:12 ` Venkat Venkatsubra
2012-10-15 17:26 ` enh
2012-10-15 21:30 ` Venkat Venkatsubra
2012-10-16 23:31 ` enh
2012-10-18 16:00 ` Venkat Venkatsubra
2012-10-18 16:53 ` Venkat Venkatsubra
2012-10-18 17:20 ` enh
2012-10-19 6:02 ` Vijay Subramanian
2012-10-19 6:50 ` Eric Dumazet
2012-10-19 8:06 ` Eric Dumazet
2012-10-19 9:14 ` Vijay Subramanian
2012-10-19 10:29 ` Eric Dumazet
2012-10-19 11:39 ` Eric Dumazet
2012-10-22 20:00 ` Vijay Subramanian
2012-10-22 20:08 ` Eric Dumazet [this message]
2012-10-22 22:11 ` Vijay Subramanian
2012-10-25 22:50 ` Eric Dumazet
2012-10-25 23:16 ` Vijay Subramanian
2012-10-18 16:54 ` Eric Dumazet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1350936519.8609.1239.camel@edumazet-glaptop \
--to=eric.dumazet@gmail.com \
--cc=enh@google.com \
--cc=netdev@vger.kernel.org \
--cc=subramanian.vijay@gmail.com \
--cc=venkat.x.venkatsubra@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox