How to get the systemd resolver to resolve local (i.e. unqalified) names?

Tom H tomh0665 at gmail.com
Sun Jun 4 09:27:31 UTC 2017


On Sat, Jun 3, 2017 at 11:34 AM, Xen <list at xenhideout.nl> wrote:
> Chris Green schreef op 03-06-2017 17:22:
>>
>> ... and this is even sillier:-
>>
>> chris at t470$ systemd-resolve esprimo
>> esprimo: 192.168.1.3
>> (esprimo.zbmc.eu)
>>
>> -- Information acquired via protocol DNS in 4.5ms.
>> -- Data is authenticated: no
>> chris at t470$ host esprimo
>> Host esprimo not found: 2(SERVFAIL)
>> chris at t470$
>
> Note that the systemd system works by changing /etc/nsswitch.conf, I
> believe. On a typical Debian 8 host this file would look like this:
>
> hosts: files mdns4_minimal [NOTFOUND=return] dns
>
> for the hosts line. I don't know what it does with you.

If you're using resolved, you can add "resolve" (before "dns") to the
"hosts" line. "libnss_resolve" will then be used to query resolved
directly.




More information about the ubuntu-users mailing list