On Sat, 13 Oct 2007, Stuart Henderson wrote:
On 2007/10/13 11:43, Karel Kulhavy wrote:
According to man resolv.conf this should result in /etc/hosts having priority
over the DNS system. However, it simply doesn't work. Both Firefox and the
"host" command behave as if I didn't do anything.
Why doesn't it work when man resolv.conf says it should?
resolv.conf(5) is correct,
The resolv.conf file specifies how the resolver(3) routines in the C li-
brary (which provide access to the Internet Domain Name System) should
operate.
N.B. Not all software uses the resolver(3) routines. Software wanting
more control of DNS queries (e.g. timeouts), more information about
responses, or async lookup, avoids them.
The resolver.conf file is a configuration file for the resolver. What is
the purpose of the host(1) command using it then, and following only a
part of it and ignoring the rest? It's really messy.
From the host(1) man page:
"server is an optional argument which is either the name or IP address of
the name server that host should query instead of the server or servers
listed in /etc/resolv.conf."
Regards,
David