From: Jeff Layton <jlayton@kernel.org>
To: Chuck Lever <chuck.lever@oracle.com>,
Daniel Gomez <da.gomez@kernel.org>,
kdevops@lists.linux.dev
Subject: Re: systemd-resolved and single-label DNS entries
Date: Tue, 26 Aug 2025 12:32:54 -0400 [thread overview]
Message-ID: <e4d9854da81d36ad8e667335f2734aa3194b79d5.camel@kernel.org> (raw)
In-Reply-To: <673f16b7-4a0f-4f2c-81e9-e4a772012e14@oracle.com>
On Tue, 2025-08-26 at 11:07 -0400, Chuck Lever wrote:
> On 8/26/25 10:21 AM, Jeff Layton wrote:
> > On Tue, 2025-08-26 at 14:53 +0200, Daniel Gomez wrote:
> > > On 26/08/2025 12.58, Jeff Layton wrote:
> > > > I'm hitting a problem with NFS testing on kdevops guests. Recently when
> > > > I bring up a guest, it's unable to resolve the name of the NFS server
> > > > via DNS.
> > >
> > > FYI, nfstests works fine with Debian testing (forky). Both hosts and guests.
> > >
> > >
> >
> >
> > Thanks. Some questions:
> >
> > 1/ did your setup get the entries in /etc/hosts? That seems to be what
> > has changed recently. That's not working for some reason.
> >
> > 2/ Does forky use systemd-resolved? The problem is clearly there with
> > Fedora 42. The DNS server on the virtual bridge works fine:
> >
> > ----------------8<-----------------
> > $ dig @192.168.122.1 kdevops-nfsd.
> >
> > ; <<>> DiG 9.18.33 <<>> @192.168.122.1 kdevops-nfsd.
> > ; (1 server found)
> > ;; global options: +cmd
> > ;; Got answer:
> > ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 24955
> > ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
> >
> > ;; OPT PSEUDOSECTION:
> > ; EDNS: version: 0, flags:; udp: 1232
> > ;; QUESTION SECTION:
> > ;kdevops-nfsd. IN A
> >
> > ;; ANSWER SECTION:
> > kdevops-nfsd. 0 IN A 192.168.122.85
> >
> > ;; Query time: 0 msec
> > ;; SERVER: 192.168.122.1#53(192.168.122.1) (UDP)
> > ;; WHEN: Tue Aug 26 10:18:47 EDT 2025
> > ;; MSG SIZE rcvd: 57
> >
> > $ resolvectl query kdevops-nfsd.
> > kdevops-nfsd.: 'kdevops-nfsd.' not found
> > ----------------8<-----------------
> >
> > It seems like we're doing something "unseemly" by putting bare names in
> > DNS like this, given that systemd-resolved won't pass them along.
> >
> > Since systemd-resolved will only resolve bare names without a domain
> > using LLMNR, we should either take steps to make that work, or fix it
> > so that systemd-resolved will forward the requests (by setting up a
> > proper domain name and setting up the search path in the resolver).
> >
>
> "won't pass them along" -- does that depend on the settings in
> /etc/nsswitch.conf ?
>
What's happening in my environment is that this list in the
update_etc_hosts playbook comes up empty:
- name: Build list of hosts
set_fact:
ueh_hosts: "{{ ansible_play_hosts_all | difference([inventory_hostname]) }}"
That recently changed in this commit:
commit 1cf0800c9ffced98da393e5d2b1594302d23eb78
Author: Daniel Gomez <da.gomez@samsung.com>
Date: Thu Jul 24 21:36:14 2025 +0200
gen_hosts: templates: include localhost in the all group
I couldn't revert that commit cleanly, so I tried out the commit just
before it, and /etc/hosts got updated correctly. I'll have to look at
proper fixes for this, but if anyone has ideas I'm happy to try them
out.
--
Jeff Layton <jlayton@kernel.org>
next prev parent reply other threads:[~2025-08-26 16:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-26 10:58 systemd-resolved and single-label DNS entries Jeff Layton
2025-08-26 12:53 ` Daniel Gomez
2025-08-26 14:21 ` Jeff Layton
2025-08-26 15:07 ` Chuck Lever
2025-08-26 15:49 ` Jeff Layton
2025-08-26 16:32 ` Jeff Layton [this message]
2025-08-26 19:04 ` Daniel Gomez
2025-08-27 13:25 ` Jeff Layton
2025-08-26 18:16 ` Daniel Gomez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e4d9854da81d36ad8e667335f2734aa3194b79d5.camel@kernel.org \
--to=jlayton@kernel.org \
--cc=chuck.lever@oracle.com \
--cc=da.gomez@kernel.org \
--cc=kdevops@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox