From owner-freebsd-stable@FreeBSD.ORG Wed Feb 19 13:53:28 2014 Return-Path: Delivered-To: stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 70452E23 for ; Wed, 19 Feb 2014 13:53:28 +0000 (UTC) Received: from mail-la0-x22f.google.com (mail-la0-x22f.google.com [IPv6:2a00:1450:4010:c03::22f]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E8E4F1919 for ; Wed, 19 Feb 2014 13:53:27 +0000 (UTC) Received: by mail-la0-f47.google.com with SMTP id hr17so303898lab.6 for ; Wed, 19 Feb 2014 05:53:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=Axhqx/F7Gxz9WvF9mOPs1cX+5glqZnWzU8akwNeLX70=; b=Gueds2bqX0BvQ+zre2MohKTFH1/sVu6t19cAzClNqUal4CRwUtwDRONSR4Leg1C+Fr C52pfk3L8iOwqWKwJckFsngY1yjA+f7x70cTHKijDLbYYLn5e10pfxrN7I6fcgqjaVnQ HBa+xo7DBGZsmm5j6juhAmEAynabNOcTJN8QR//epagn/CwoynpqA6rTXY2HW+MPrdVe nYaWdRY9sqIw4jn+fdlwnTzMhthxOQAtRZALAWjzZz5Jr/YylbQKQ6KjgYQD8Qurmtb0 m+qXx1cr8UOTzsmfuP3liew7cu6boGh4HaiVY4E+TfSSAHHqQiPuyuutz5JFx3kqpw0S zE2g== X-Received: by 10.112.164.35 with SMTP id yn3mr1773589lbb.45.1392818005800; Wed, 19 Feb 2014 05:53:25 -0800 (PST) Received: from ?IPv6:2a02:6b8::408:41f9:4330:830:f055? ([2a02:6b8:0:408:41f9:4330:830:f055]) by mx.google.com with ESMTPSA id h7sm316736lbj.1.2014.02.19.05.53.22 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 19 Feb 2014 05:53:22 -0800 (PST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 7.1 \(1827\)) Subject: Re: options timeout in resolv.conf does not work in stable/10 From: Dmitry Sivachenko In-Reply-To: <5304B65C.1040500@gmail.com> Date: Wed, 19 Feb 2014 17:53:20 +0400 Content-Transfer-Encoding: quoted-printable Message-Id: References: <40E84CA7-E815-4B5E-AF0F-4B29C8B58186@gmail.com> <5304B65C.1040500@gmail.com> To: Vitaly Magerya X-Mailer: Apple Mail (2.1827) Cc: stable@freebsd.org X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Feb 2014 13:53:28 -0000 On 19 =D1=84=D0=B5=D0=B2=D1=80. 2014 =D0=B3., at 17:49, Vitaly Magerya = wrote: > Dmitry Sivachenko wrote: >> I have the following /etc/resolv.conf: >>=20 >> domain domain.my >> nameserver IP1 >> nameserver IP2 >> options timeout:1 >>=20 >>=20 >> On FreeBSD-9-STABLE, if IP1 is down, I get a dns response from IP2 = after 1 second. >> On FreeBSD-10, I get dns response from IP2 after 10 seconds. >>=20 >> I see no changes in resolv.conf(5) man-page about timeout parameter. >>=20 >> What am I missing? >=20 > Are you using host(1) command for this? I used drill(1), which probably also uses ldns and does not respect = optons? Also I noticed that drill(1) does not respect nameserver's order from = resolv.conf, and picks random one. Which is also strange and disappointing. > If so, host(1) in > 10-RELEASE does not respect 'options' from resolv.conf (there's > a note about this in it's man page); the system resolver (that > is, anything based on getaddrinfo(3)) should not be affected > though. >=20 > The reason for this regression is that host(1) is now based on > the ldns library, which doesn't currently parse the 'options' > directive (e.g. see [1]). >=20 > The solution is to add '-w 1' to the list of host(1) options. > Or to push the ldns folks to fix this. >=20 > [1] = http://git.nlnetlabs.nl/ldns/tree/resolver.c?id=3Df328ba0ccc3c0733d0451d50= 59b50e502206923a#n838