public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: John Heffner <johnwheffner@gmail.com>
Cc: Nandita Dukkipati <nanditad@google.com>,
	"David S. Miller" <davem@davemloft.net>,
	netdev@vger.kernel.org, Tom Herbert <therbert@google.com>,
	Laurent Chavey <chavey@google.com>,
	Yuchung Cheng <ycheng@google.com>
Subject: Re: [PATCH 1/1] TCP: increase default initial receive window.
Date: Tue, 21 Dec 2010 19:49:07 +0100	[thread overview]
Message-ID: <1292957347.2720.45.camel@edumazet-laptop> (raw)
In-Reply-To: <AANLkTikcS-U9yA05dTp_y4EciwtUsjSonjc+bkA=57=4@mail.gmail.com>

Le mardi 21 décembre 2010 à 13:27 -0500, John Heffner a écrit :
> I know this has already been applied, but one thing to think about:
> Linux announces a small initial window to prevent overflowing the
> receive buffer when receiving segments smaller than the link MTU.

Overflowing receive buffer ? Which one ? Do you mean NIC RX ring
buffer ?

> Increasing this even to 10 segments might have some negative
> consequences.  I recall, for instance, some drivers when configured
> with a 9000 byte MTU, have a single pool of receive buffers all 16k
> (the next highest power of 2).  So each received segment will get 16k
> of allocated memory accounted to it, even if the incoming segments are
> <=1460 bytes long.  The default initial rcvbuf of 87380 bytes is less
> than the 160k of memory that the initial window might consume, so
> we're going to start hitting the very slow path of coalescing segments
> to get back under memory bounds.

Patch is not allowing 87380 bytes, but 10 segments, limited to 14600
bytes. Its very conservative IMHO.

> 
> Some drivers are smarter about having multiple pools of receive
> buffers with different sizes, so it might not be so easy to hit this
> condition.  I haven't looked at any of them for a while.  Is this
> still a real concern?

I dont think so. You would have problem anyway, since the patch changes
only _initial_ receive window. After some kbytes of data exchanged,
window is probably larger.



      reply	other threads:[~2010-12-21 18:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-18  3:20 [PATCH 1/1] TCP: increase default initial receive window Nandita Dukkipati
2010-12-18  3:59 ` Stephen Hemminger
2010-12-18  5:14   ` David Miller
2010-12-18  5:13 ` David Miller
2010-12-18  9:08   ` Nandita Dukkipati
2010-12-20 17:03     ` Stephen Hemminger
2010-12-20 18:26       ` Rick Jones
2010-12-20 18:48         ` David Miller
2010-12-21  0:15 ` [PATCH v2 " Nandita Dukkipati
2010-12-21  0:23   ` Nandita Dukkipati
2010-12-21  5:00   ` Eric Dumazet
2010-12-21  5:33     ` David Miller
2010-12-21 18:27 ` [PATCH " John Heffner
2010-12-21 18:49   ` Eric Dumazet [this message]

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=1292957347.2720.45.camel@edumazet-laptop \
    --to=eric.dumazet@gmail.com \
    --cc=chavey@google.com \
    --cc=davem@davemloft.net \
    --cc=johnwheffner@gmail.com \
    --cc=nanditad@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=therbert@google.com \
    --cc=ycheng@google.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