How to get the systemd resolver to resolve local (i.e. unqalified) names?
Xen
list at xenhideout.nl
Sun Jun 4 13:59:24 UTC 2017
Tom H schreef op 04-06-2017 15:40:
> So getent works with the libnss_resolve module but not with the
> libnss_dns module.
No, the libnss_dns module just doesn't work without "search".
> So "host" fails with both "resolve" and "dns" (previously it was
> failing with "resolve" and returning).
It doesn't use nsswitch.
> The problem seems to be that host and dig can only resolve short
> ("zero-dotted? LOL) hostnames if there's a domain or search entry in
> "/etc/resolv.conf"; and it might or might not be related to the fact
> that LLMNR cannot be turned off
Yes.
But systemd-resolved apparently requires the search directive when
accessed through 127.0.0.53 as it expects these queries to conform to
the /etc/resolv.conf specification.
The problem is that host doesn't go through that,
but a command like "ping" probably would.
I mean the reverse: host goes directly to /etc/resolv.conf,
while "ping" probably uses /etc/nsswitch.conf.
So most ordinary programs would work, just not programs that have their
own individual DNS resolving.
Thus, programs that talk DNS directly fail to work.
More information about the ubuntu-users
mailing list