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

Chris Green cl at isbd.net
Sun Jun 4 12:18:41 UTC 2017


On Sun, Jun 04, 2017 at 08:00:33AM -0400, Tom H wrote:
> On Sun, Jun 4, 2017 at 6:50 AM, Chris Green <cl at isbd.net> wrote:
> > On Sun, Jun 04, 2017 at 06:19:00AM -0400, Tom H wrote:
> 
> 
> >> You'd posted that "systemd-resolve ..." returned the correct address
> >> but that "host ..." didn't. Have you tried "dig ..." or "drill ..."?
> >> (I'd expect them to fail too.)
> >>
> > system-resolve and getent find the right IP for an unqualified name.
> >
> > host and dig return SERVFAIL.
> 
> As I just said in another email, bug!
> 
> Are you going to file a report?
> 
I have an account on the bug reporting system so I will do so.

> 
> > If I manually add 'search zbmc.eu' to /etc/resolv.conf then everything
> > works as it should (or at least as I want!).
> >
> > On my older (xubuntu 16.04) systems /etc/resolv.conf *does* have the
> > search line:-
> >
> > # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
> > # DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
> > nameserver 127.0.1.1
> > search zbmc.eu
> >
> > So it would seem there's something wrong with the xubuntu 17.04
> > dhclient and resolvconf setup, or for some reason it thinks it doesn't
> > need to put the search line in even though the DHCP server is sending
> > it the information.
> >
> > As a temporary fix I will add 'search zbmc.eu' to /etc/resolvconf/resolv.conf.d/head,
> > at least this won't get lost over reboots though it's a bit of a bodge.
> 
> It's a good workaround until resolved fixes itself. I don't think that
> dhclient and resolvconf are to blame.
> 
But its dhclient->resolvconf that writes /etc/resolv.conf isn't it?
On 16.04 they manage to put 'search zbmc.eu' there whereas in 17.04
they don't.  I think the DHCP server must be doing the right thing as
otherwise 16.04 woudn't pick up the domain.

-- 
Chris Green




More information about the ubuntu-users mailing list