options timeout in resolv.conf does not work in stable/10

Dmitry Sivachenko trtrmitya at gmail.com
Wed Feb 19 13:53:28 UTC 2014


On 19 февр. 2014 г., at 17:49, Vitaly Magerya <vmagerya at gmail.com> wrote:

> Dmitry Sivachenko wrote:
>> I have the following /etc/resolv.conf:
>> 
>> domain domain.my
>> nameserver IP1
>> nameserver IP2
>> options timeout:1
>> 
>> 
>> 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.
>> 
>> I see no changes in resolv.conf(5) man-page about timeout parameter.
>> 
>> What am I missing?
> 
> 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.
> 
> 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]).
> 
> The solution is to add '-w 1' to the list of host(1) options.
> Or to push the ldns folks to fix this.
> 
> [1] http://git.nlnetlabs.nl/ldns/tree/resolver.c?id=f328ba0ccc3c0733d0451d5059b50e502206923a#n838



More information about the freebsd-stable mailing list