From owner-freebsd-stable@FreeBSD.ORG Thu Feb 18 15:50:57 2010 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2AE8106566B for ; Thu, 18 Feb 2010 15:50:57 +0000 (UTC) (envelope-from h.schmalzbauer@omnilan.de) Received: from host.omnilan.net (host.omnilan.net [62.245.232.135]) by mx1.freebsd.org (Postfix) with ESMTP id 2604C8FC13 for ; Thu, 18 Feb 2010 15:50:56 +0000 (UTC) Received: from titan.flintsbach.schmalzbauer.de (titan.flintsbach.schmalzbauer.de [172.21.1.150]) (authenticated bits=0) by host.omnilan.net (8.13.8/8.13.8) with ESMTP id o1IFotRh039188 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 18 Feb 2010 16:50:55 +0100 (CET) (envelope-from h.schmalzbauer@omnilan.de) Message-ID: <4B7D61DE.2020906@omnilan.de> Date: Thu, 18 Feb 2010 16:50:54 +0100 From: Harald Schmalzbauer Organization: OmniLAN User-Agent: Thunderbird 2.0.0.23 (X11/20090906) MIME-Version: 1.0 To: Patrick Mahan References: <4B7C1365.9070806@omnilan.de> <70CD649D-7659-4CE2-A16C-49B8C891CB5B@mac.com> <4B7C4066.5040006@omnilan.de> <4B7D3938.1000309@omnilan.de> <4B7D5AC4.9020509@mahan.org> In-Reply-To: <4B7D5AC4.9020509@mahan.org> X-Enigmail-Version: 0.95.6 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig940FE569D003DF9BA36FBBAE" Cc: freebsd-stable@freebsd.org Subject: RELENG_8 ignoring TCP window size? [Was: Re: Help for TCP understanding wanted, ACK-MSS-Window [Was: Re: best practice to watch TCP parms of established sockets]] X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Feb 2010 15:50:57 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig940FE569D003DF9BA36FBBAE Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Patrick Mahan schrieb am 18.02.2010 16:20 (localtime): > See inline... =2E.. >> Please clarify my TCP understanding. >> If I have the window set to 65535 in the header and a MSS of 1460, how= =20 >> often should the receiver send ACK segments? window/MSS, right? >=20 > How soon you see the ACK is based on two values in the kernel: > net.inet.tcp.delacktime > net.inet.tcp.delayed_ack >=20 > The first one controls how soon the peer replies with an ACK if there i= s > no data to send back, ie. it is just a plain ack. Van Jacobson first > recommended it in the early days of TCP/IP. Historically, it has been > implemented as a 200 ms timer, but in FreeBSD it is a 100 ms timer. Thank you for your hint. I heard of that but never thought about it,=20 because 100ms is a magnitude higher than my =B5s LAN delay and since I'm = not suffering from extremeley slow speeds. =2E.. >> a) why disabling net.inet.tcp.rfc1323 gives slightly better rsync=20 >> throughput than enabled >=20 > rfc1323 deals with window scaling and timestamp options. Perhaps these= > are getting in the way? >=20 >> b) why I can't transfer more than 50MB/s over my direct linked GbE box= es. >> >> But right now I even don't understand the dump I see. As far as I=20 >> understand I should only see every 45 data segments one ACK segment.=20 >> That would clearly explain to me why I can't saturate my GbE link. But= =20 >> I can't imagine this is a uncovered faulty behaviour, so I guess I=20 >> haven't understood TCP. >> >=20 > No we are also seeing similar behavior over the em(4) interface under > FreeBSD 8.0-Stable. Some experimental results: When rsyncing with windows, and FreeBSD is receiver, I see the same ACK=20 ever two segemnts, but speed is at 72MB/s. When FreeBSD is sender and Windows is receiver, it looks more I=20 expected. There are about 20 data segments before a ACK is returned. And = there are TCP Window Update Segments, reflecting smaller receiver=20 buffers on the windows side. But this happens at a throughput of=20 82MB/s!!! So the windows machine is behaving like I understand the TCP=20 flow control. Any explanation why the FreeBSD machine seems to ignore window size? Thanks, -Harry --------------enig940FE569D003DF9BA36FBBAE Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.13 (FreeBSD) iEYEARECAAYFAkt9Yd8ACgkQLDqVQ9VXb8iOlwCgvD6US4J6+km41ndHL0eL9NUw YqoAn22a8BMVi+VNzqBPcA59il03x3df =FBYQ -----END PGP SIGNATURE----- --------------enig940FE569D003DF9BA36FBBAE--