From owner-freebsd-questions@FreeBSD.ORG Wed Dec 6 23:45:22 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6388716A47E for ; Wed, 6 Dec 2006 23:45:22 +0000 (UTC) (envelope-from wmoran@collaborativefusion.com) Received: from mx00.pub.collaborativefusion.com (mx00.pub.collaborativefusion.com [206.210.89.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id B762343CA8 for ; Wed, 6 Dec 2006 23:44:33 +0000 (GMT) (envelope-from wmoran@collaborativefusion.com) Received: from working (c-71-60-174-60.hsd1.pa.comcast.net [71.60.174.60]) (AUTH: LOGIN wmoran, TLS: TLSv1/SSLv3,256bits,AES256-SHA) by wingspan with esmtp; Wed, 06 Dec 2006 18:45:20 -0500 id 00056447.45775610.00008749 Date: Wed, 6 Dec 2006 18:45:19 -0500 From: Bill Moran To: freebsd@sopwith.solgatos.com Message-Id: <20061206184519.f3ceefb5.wmoran@collaborativefusion.com> In-Reply-To: <200612062246.WAA17265@sopwith.solgatos.com> References: <200612062246.WAA17265@sopwith.solgatos.com> Organization: Collaborative Fusion Inc. X-Mailer: Sylpheed version 2.2.10 (GTK+ 2.10.6; i386-portbld-freebsd6.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: TCP parameters and interpreting tcpdump output X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Dec 2006 23:45:22 -0000 Dieter wrote: > > I found a couple more things that don't look right. > > 000017 IP bsd.63743 > src.65001: . ack 52 win 65535 > 000107 IP bsd.63743 > src.65001: . ack 52 win 65535 > 000012 IP bsd.63743 > src.65001: F 52:52(0) ack 52 win 65535 > 000005 IP bsd.63743 > src.65001: F 52:52(0) ack 52 win 65535 > 000172 IP src.65001 > bsd.63743: . ack 53 win 4096 > 000004 IP src.65001 > bsd.63743: F 52:52(0) ack 53 win 4096 > 000003 IP src.65001 > bsd.63743: . ack 53 win 4096 > 000016 IP bsd.63743 > src.65001: . ack 52 win 65535 > 000011 IP bsd.63743 > src.65001: . ack 53 win 112 <------ why does the window suddenly shrink? > 002366 IP src.rfe > bsd.12340: P 1:1317(1316) ack 1 win 4096 > 099554 IP bsd.12340 > src.rfe: . ack 1317 win 65535 <------ why does it take 99.5 millisec to ack? > > The ack time is normally 12 or 13 microseconds, which seems to be okay. > But 99.5 milliseconds is *way* too slow, data will be lost. > > Is TCP sitting around waiting for a second packet, so that > it can be "efficient" and ack two packets at once? sysctl -d net.inet.tcp.delayed_ack net.inet.tcp.delayed_ack: Delay ACK to try and piggyback it onto a data packet That sysctl will turn it off for all network connections on the system. You can also set it on a per-socket basis using setsockopt and the TCP_NODELAY option. Some google searches on TCP_NODELAY will provide interesting technical details. -Bill