interop problems with getaddrinfo() address selection

Tony Finch <dot@dotat.at> Thu, 06 December 2007 19:03 UTC

Return-path: <discuss-bounces@apps.ietf.org>
Received: from [127.0.0.1] (helo=stiedprmman1.va.neustar.com) by megatron.ietf.org with esmtp (Exim 4.43) id 1J0M0Y-0006Gd-Qc; Thu, 06 Dec 2007 14:03:38 -0500
Received: from discuss by megatron.ietf.org with local (Exim 4.43) id 1J0M0X-00066e-5s for discuss-confirm+ok@megatron.ietf.org; Thu, 06 Dec 2007 14:03:37 -0500
Received: from [10.91.34.44] (helo=ietf-mx.ietf.org) by megatron.ietf.org with esmtp (Exim 4.43) id 1J0M0W-00064D-Qi for discuss@apps.ietf.org; Thu, 06 Dec 2007 14:03:36 -0500
Received: from ppsw-1.csi.cam.ac.uk ([131.111.8.131]) by ietf-mx.ietf.org with esmtp (Exim 4.43) id 1J0M0T-0008Nd-61 for discuss@apps.ietf.org; Thu, 06 Dec 2007 14:03:36 -0500
X-Cam-SpamDetails: Not scanned
X-Cam-AntiVirus: No virus found
X-Cam-ScannerInfo: http://www.cam.ac.uk/cs/email/scanner/
Received: from hermes-1.csi.cam.ac.uk ([131.111.8.51]:51565) by ppsw-1.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.151]:25) with esmtpa (EXTERNAL:fanf2) id 1J0M0R-00072w-5I (Exim 4.67) (return-path <fanf2@hermes.cam.ac.uk>); Thu, 06 Dec 2007 19:03:31 +0000
Received: from fanf2 (helo=localhost) by hermes-1.csi.cam.ac.uk (hermes.cam.ac.uk) with local-esmtp id 1J0M0R-000498-KD (Exim 4.67) (return-path <fanf2@hermes.cam.ac.uk>); Thu, 06 Dec 2007 19:03:31 +0000
Date: Thu, 6 Dec 2007 19:03:31 +0000
From: Tony Finch <dot@dotat.at>
X-X-Sender: fanf2@hermes-1.csi.cam.ac.uk
To: discuss@apps.ietf.org
Subject: interop problems with getaddrinfo() address selection
Message-ID: <Pine.LNX.4.64.0712061901020.24448@hermes-1.csi.cam.ac.uk>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
X-Spam-Score: 0.0 (/)
X-Scan-Signature: 2409bba43e9c8d580670fda8b695204a
Cc: Ian Jackson <ian@davenant.greenend.org.uk>
X-BeenThere: discuss@apps.ietf.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: general discussion of application-layer protocols <discuss.apps.ietf.org>
List-Unsubscribe: <https://www1.ietf.org/mailman/listinfo/discuss>, <mailto:discuss-request@apps.ietf.org?subject=unsubscribe>
List-Post: <mailto:discuss@apps.ietf.org>
List-Help: <mailto:discuss-request@apps.ietf.org?subject=help>
List-Subscribe: <https://www1.ietf.org/mailman/listinfo/discuss>, <mailto:discuss-request@apps.ietf.org?subject=subscribe>
Errors-To: discuss-bounces@apps.ietf.org

Rule 9 of RFC 3484 specifies that the IP addresses (v4 and v6) returned by
getaddrinfo() should be sorted according to the size of their common
prefix with the local host's chosen source IP address. This defeats DNS
round robin load balancing which has led to some severe operational
problems. DNS round robin needs to be documented in an RFC, and RFC 3484
should be updated with rule 9 deleted or substantially modified for
compatibility with DNS round robin.

Ian Jackson has written a thorough description of the problem from the
perspective of a proposal that Debian's version of glibc should have the
troublesome sorting behaviour removed:

http://lists.debian.org/debian-ctte/2007/11/msg00029.html

FreeBSD's getaddrinfo() only implements Rule 9 if the kernel's address
selection policy is configured, which is not done by default so DNS round
robin is honoured.

[I originally posted this to the dnsop WG list, but they don't seem to
understand or care about the problem...]

Tony.
-- 
f.a.n.finch  <dot@dotat.at>  http://dotat.at/
SOLE LUNDY FASTNET: WEST VEERING NORTHWEST 6 TO GALE 8, INCREASING GALE 8 TO
STORM 10 FOR A TIME. VERY ROUGH OR HIGH. RAIN OR SQUALLY SHOWERS. MODERATE OR
GOOD.