Re: [tcpm] Nagle Algorithm and Delayed ACKs

Carsten Bormann <cabo@tzi.org> Sat, 25 July 2009 05:17 UTC

Return-Path: <cabo@tzi.org>
X-Original-To: tcpm@core3.amsl.com
Delivered-To: tcpm@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 747C23A6975 for <tcpm@core3.amsl.com>; Fri, 24 Jul 2009 22:17:55 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.249
X-Spam-Level:
X-Spam-Status: No, score=-6.249 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, HELO_EQ_DE=0.35, RCVD_IN_DNSWL_MED=-4]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id X1qbhr4pBzTN for <tcpm@core3.amsl.com>; Fri, 24 Jul 2009 22:17:54 -0700 (PDT)
Received: from informatik.uni-bremen.de (mailhost.informatik.uni-bremen.de [IPv6:2001:638:708:30c9:209:3dff:fe00:7136]) by core3.amsl.com (Postfix) with ESMTP id 155333A69A3 for <tcpm@ietf.org>; Fri, 24 Jul 2009 22:17:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at informatik.uni-bremen.de
Received: from smtp-fb3.informatik.uni-bremen.de (smtp-fb3.informatik.uni-bremen.de [134.102.224.120]) by informatik.uni-bremen.de (8.14.3/8.14.3) with ESMTP id n6P5HSVd012741; Sat, 25 Jul 2009 07:17:29 +0200 (CEST)
Received: from [192.168.217.107] (p5489BEB8.dip.t-dialin.net [84.137.190.184]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by smtp-fb3.informatik.uni-bremen.de (Postfix) with ESMTP id 89842B79D; Sat, 25 Jul 2009 07:17:28 +0200 (CEST)
From: Carsten Bormann <cabo@tzi.org>
To: Thomas Narten <narten@us.ibm.com>
In-Reply-To: <200907241952.n6OJqMVZ006081@cichlid.raleigh.ibm.com>
References: <200907241952.n6OJqMVZ006081@cichlid.raleigh.ibm.com>
Message-Id: <37C0C058-7364-4ACD-A5ED-AACA51F8B567@tzi.org>
Content-Type: text/plain; charset="US-ASCII"; format="flowed"; delsp="yes"
Content-Transfer-Encoding: 7bit
Mime-Version: 1.0 (Apple Message framework v935.3)
Date: Sat, 25 Jul 2009 07:17:26 +0200
X-Mailer: Apple Mail (2.935.3)
Cc: tcpm@ietf.org
Subject: Re: [tcpm] Nagle Algorithm and Delayed ACKs
X-BeenThere: tcpm@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: TCP Maintenance and Minor Extensions Working Group <tcpm.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/tcpm>, <mailto:tcpm-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/tcpm>
List-Post: <mailto:tcpm@ietf.org>
List-Help: <mailto:tcpm-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/tcpm>, <mailto:tcpm-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 25 Jul 2009 05:17:55 -0000

On Jul 24, 2009, at 21:52, Thomas Narten wrote:

> TCP_NODELAY

My view would be that this is a well-documented option in the socket  
interface.
Even though the interaction with delayed ACKs is rarely explained  
correctly, there are lots of "Socket FAQ" and "Tuning Guide" documents  
that explain "Nagling" (ouch) and the TCP_NODELAY socket option (I get  
117000 google hits...).
TCP_NODELAY certainly is standard fare in any reasonable socket API  
course.
People already need to think about the number of write/send operations  
they perform for one message.
(Note that Linux also has TCP_CORK.)

In essence, the kernel needs to know whether the programmer was not  
considering the issue (making it likely there will be lots of silly  
small writes) or whether the issue was considered and the program is  
optimized with respect to the writes.
A socket option defaulting to the first case sounds like the right way  
to communicate that information, which is hard to infer.

What would you want to improve?

Gruesse, Carsten