Contributors have claimed here (bug #993298) above that /etc/hosts is no
longer respected, but that is not the case. As always, with
hosts: files [...]
in /etc/nsswitch.conf, the libc resolver consults /etc/hosts first.
Yes, NM runs dnsmasq with the no-hosts option. Consequently a DNS lookup
on 127.0.0.1 does not respect /etc/hosts. But prior to Ubuntu 12.04, NM
didn't start a local nameserver at all; no DNS lookups were done
externally and /etc/hosts wasn't respected then either.
The contributors who say that /etc/hosts is "no longer" consulted must
(I conclude) have been running the standalone server version of dnsmasq
before. That dnsmasq respects /etc/hosts and listens at 127.0.0.1 by
default. Now, because of bug #959037 it is not possible in Ubuntu 12.04
to run standalone dnsmasq alongside nm-dnsmasq. But it *is* possible to
run standalone dnsmasq if nm-dnsmasq is disabled (by commenting out
"dns=dnsmasq" in /etc/NetworkManager/NetworkManager.conf and restarting
network-manager) and that should restore the old situation.
Assuming that the underlying wish is that standalone dnsmasq can be run
without the need to comment out "dns=dnsmasq", I propose to merge this
report with #959037 which discusses ways of realizing this. See, for
example, comment #88 in that bug report.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/993298
Title:
Please make NetworkManager-controlled dnsmasq respect /etc/hosts
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/993298/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs