netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* can TCP socket send buffer be over used?
@ 2010-08-04  0:22 Jack Zhang
  2010-08-04  0:30 ` Rick Jones
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jack Zhang @ 2010-08-04  0:22 UTC (permalink / raw)
  To: netdev

Hi there,

I'm doing experiments with (modified*) software iSCSI over a link with
an emulated Round-Trip Time (RTT) of 100 ms by netem.

For example, when I set the send buffer size to 128 KB, i could get a
throughput up to 43 Mbps, which seems to be impossible as the (buffer
size) / RTT is only 10 Mbps.
And When I set the send buffer size to 512 KB, i can get a throughput
up to 60 Mbps, which also seems to be impossible as the (buffer size)
/ RTT is only 40 Mbps.

I understand that when the buffer size is set to 128 KB, I actually
got a buffer of 256 KB as the kernel doubles the buffer size. I also
understand that half the doubled buffer size is used for meta data
instead of the actual data to be transferred. So basically the
effective buffer sizes for the two examples  are just 128 KB and 512
KB respectively.

So I was confused because, theoretically, send buffers of 128 KB and
512 KB should achieve no more than 10 Mbps and 40 Mbps respectively
but I was able to get way much more than the theoretical limit. So
I was wondering is there any chance the send buffer can be "overused"?
or there is some other mechanism inside TCP is doing some
optimization?

* the modification is to disable "TCP_NODELAY" , enable
"use_clustering" for SCSI, and set different send buffer sizes for the
TCP socket buffer.

Any idea will be highly appreciated.

Thanks a lot!

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2010-08-04  9:07 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-04  0:22 can TCP socket send buffer be over used? Jack Zhang
2010-08-04  0:30 ` Rick Jones
2010-08-04  0:48   ` Jack Zhang
2010-08-04  1:17     ` Rick Jones
2010-08-04  7:20 ` Bill Fink
2010-08-04  8:00   ` Jack Zhang
2010-08-04  9:07     ` Bill Fink
2010-08-04  7:33 ` Mikael Abrahamsson
2010-08-04  8:03   ` Jack Zhang
2010-08-04  8:21     ` Mikael Abrahamsson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).