[Dnsmasq-discuss] dnsmasq-2.18: ignoring nameserver 127.0.0.1
- local interface
Sat, 27 Nov 2004 10:24:33 +0000
> I _THINK_ I understand the docs correctly <g>. Herewith all the facts I
> believe are pertinent:
> search chsoft.biz
> nameserver 127.0.0.1
> The linux box has 2 NICs. eth0 faces the LAN and eth1 faces the
> internet. Its name is ns.chsoft.biz, from which you will correctly
> assume that it is the name server. There is a block of 5 usable IPs and
> this machine is on the last usable IP (.158). It runs axfrdns and
> tinydns but *not* dnscache because I believe dnscache is abusive of the
> root servers. I want dnsmasq to provide DNS for the entire LAN,
> including itself.
> I hope it is safe to ignore the fact that this machine uses proxyARP so
> that it listens to all 5 of the external IPs on eth1 and then forwards
> to the correct machine via a complex routing table on eth0. If we have
> to "go there", it really complicates this discussion. It should not be
> relevant, but what do I know?!!
> THE PROBLEM:
> When I put localhost ("nameserver 127.0.0.1") into /etc/resolv.conf
> (refer to the above resolv.conf) and start dnsmasq, dnsmasq reports this
> "ignoring nameserver 127.0.0.1 - local interface"
> Side note: a google search finds many instances of this error message.
> I cannot figure out how to configure dnsmasq to act as a cache for the
> host on which it is running. Frankly, this is not "a must" because this
> Linux box runs only sshd, axfrdns and tinydns. Nevertheless, I want
> this to work.
> Please advise.
So I think that you've already succeeded: have you looked in the log to
see if DNS queries from this host are passing through dnsmasq? My guess
is that they are.
The reason for the "ignoring nameserver" is that dnsmasq is looking in
/etc/resolv.conf for upstream nameservers, as well as in
/etc/dnsmasq.conf, so it ends up with the set of (127.0.0.1,
22.214.171.124, 126.96.36.199) as upstream nameservers. However, dnsmasq
also knows that it is listening on 127.0.0.1 for DNS queries, so it's
clever enough to ignore that - and tell you about it. This is quite
important, since looping-back queries will cause them to circulate
hundreds of times until tables are filled and the query gets thrown away.
To get rid of the warning, you can tell dnsmasq not to read
/etc/resolv.conf, by adding "no-resolv" to /etc/dnsmasq.conf