Re: Tweaking TCP windowsize
Re: Tweaking TCP windowsize
- Subject: Re: Tweaking TCP windowsize
- From: Andreas Fink <email@hidden>
- Date: Thu, 23 Jun 2011 13:57:41 +0200
Brandon,
well spotted, I wanted a 6M window, not a 6G window of course!
The calculation is like this
we have a wirespeed of 1'000'000'000 bits / second which is 125'000'000 bytes per second.
The point to point connection has a roundtrip delay of 50ms = 0.05 sec
Which means if we are sending full blast on one end until we get the ACK back for the first bit we sent, we have already sent 125'000'000 * 0.05 bytes down the wire which is 6'250'000 bytes or approx 6M.
Our fist test was a http download of XCode from apple's servers and the performance was like 1kbyte/sec.
Our second test was a sccp transfer from point to point to get it there faster and performance was also lousy.
So by further testing we used iperf which apparently tests with 64k window size and we ended up at like 8Mbit/sec which matches well the above calculation.
On 23.06.2011, at 10:32, Brandon Becker wrote:
> Hi Andreas,
>
> You mention trying to set a 6M window size, but the command you're using attempts to set a 6G window. How do you know that making the window size 100 times bigger will also make network throughput 100 times faster?
>
> I can't answer your questions and have very little experience tuning network performance, but I am very interested in watching this discussion.
>
> Brandon Becker
> Macs in Alaska LLC
>
>
>
> On Jun 22, 2011, at 10:38 PM, Andreas Fink wrote:
>
>> Hello,
>>
>> We run a datacenter in Iceland and as such we are transferring lots of data from central europe to/from Iceland.
>> We realized that we never get over 10Mbps of speed while we have a dedicated point to point 1Gbps link in between.
>>
>> The problem is that filetransfers over TCP get slowed down by the window size which defaults to 64k. As there is 50ms delay between the sites, the window size does slam the breaks on the speed.
>>
>>
>> I now want to change the default send window size to 6M so it would give us one full gigabit. However setting it with
>>
>> sysctl -w net.inet.tcp.sendspace=6442450944
>>
>> results in
>>
>> sysctl: net.inet.tcp.sendspace: Result too large
>>
>>
>> which raises the following questions:
>> a) what is the maximum value in the standard kernel?
>> b) how can it be increased
>>
>> And can the window size not be dynamically expanded once its hit?
>>
>> I think in todays world 64k is way too low. A lot of destinations are 150ms delays away, simply by the fact they are at the other side of the planet. And speeds above 10Mbps for home users are very common while in the datacenters 1Gbps is common and everyone moves to 10GBps.
>
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden