From owner-freebsd-hackers@FreeBSD.ORG Sat Aug 2 00:45:48 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1415C37B401 for ; Sat, 2 Aug 2003 00:45:48 -0700 (PDT) Received: from smtp.netli.com (ip2-pal-focal.netli.com [66.243.52.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3ABD243FAF for ; Sat, 2 Aug 2003 00:45:47 -0700 (PDT) (envelope-from vlm@netli.com) Received: (qmail 6797 invoked by uid 84); 2 Aug 2003 07:45:46 -0000 Received: from vlm@netli.com by l3-1 with qmail-scanner-0.96 (uvscan: v4.1.40/v4121. . Clean. Processed in 0.140734 secs); 02 Aug 2003 07:45:46 -0000 Received: from unknown (HELO netli.com) (172.17.1.12) by mx01-pal-lan.netli.lan with SMTP; 2 Aug 2003 07:45:46 -0000 Message-ID: <3F2B6C88.5020908@netli.com> Date: Sat, 02 Aug 2003 00:47:20 -0700 From: Lev Walkin Organization: Netli, Inc. User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.3.1) Gecko/20030521 X-Accept-Language: ru, en-us, en MIME-Version: 1.0 To: Luigi Rizzo References: <20030801235200.A53695@xorpc.icir.org> In-Reply-To: <20030801235200.A53695@xorpc.icir.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: hackers@freebsd.org Subject: Re: can we disable AAAA queries in the resolver ? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Aug 2003 07:45:48 -0000 Luigi Rizzo wrote: > hi, > recently i have been bitten by a problem which might be already > known, but still... > > quite a few apps (sendmail and ssh among them) seem to always > try an AAAA query if compiled with ipv6 support, and even if > the kernel does not support ipv6, tcpdump shows AAAA queries going out > to the nameserver, and often timing out or otherwise causing my > apps significand delays at startup. > > My understanding is that there are multiple buggy components here: > my ISP's nameserver certainly shouldn't behave so badly on AAAA > requests, and the applications should not bother asking AAAA queries > when the kernel has no ipv6 support. > On the other hand, the resolver code is probably just innocent > because if some application issues an AAAA request, the resolver > has no reason to object. Still, rather than fixing the many > broken applications, or the nameserver (on which i have no control) > i wonder if it is possible to instruct the resolver, perhaps through > some option in resolv.conf, to immediately return some kind > of negative replies on selected queries ? The code does not seem to have this as an option, but it is rather a compile-time stuff. Refer to the /usr/src/lib/libc/net/getaddrinfo.c. Indeed, it would be useful to have it configurable either in resolv.conf (options) or as an environment variable (RES_OPTIONS). -- Lev Walkin vlm@netli.com