Bug#767410: systemd-resolved: doesn't include local search domain from DHCP query into resolv.conf

Stefan Lippers-Hollmann s.L-H at gmx.de
Thu Oct 30 21:25:55 GMT 2014


Package: systemd
Version: 215-5
Severity: minor
Tags: upstream patch

Hi

Using systemd-resolved, the local searchdomain provided by the DHCP 
server is not added to resolv.conf, which disables FQDN completion 
without domain suffix.

e.g.:

$ ls -al /etc/resolv.conf 
lrwxrwxrwx 1 root root 32 Okt 17 20:00 /etc/resolv.conf -> /run/systemd/resolve/resolv.conf

$ cat /run/systemd/resolve/resolv.conf 
# This file is managed by systemd-resolved(8). Do not edit.
#
# Third party programs must not access this file directly, but
# only through the symlink at /etc/resolv.conf. To manage
# resolv.conf(5) in a different way, replace the symlink by a
# static file or a different symlink.

nameserver 10.0.0.1
nameserver 8.8.8.8
nameserver 8.8.4.4
# Too many DNS servers configured, the following entries may be ignored
nameserver 2001:4860:4860::8888
nameserver 2001:4860:4860::8844

Domain name without domain suffix:

$ nslookup redstone
Server:         10.0.0.1
Address:        10.0.0.1#53

Non-authoritative answer:
*** Can't find redstone: No answer

FQDN, with full (local-) domain suffix:

$ nslookup redstone.lan
Server:         10.0.0.1
Address:        10.0.0.1#53

Name:   redstone.lan
Address: 10.10.7.0


This seems to have been reported upstream under

	https://bugs.freedesktop.org/show_bug.cgi?id=79671

and probably also

	https://bugs.freedesktop.org/show_bug.cgi?id=85397

The formal patch that was actually merged upstream 

	http://cgit.freedesktop.org/systemd/systemd/commit/?id=6192b846ca0d15602e94ddb5da4420b7c60d64a5

doesn't apply easily to systemd 215, but the initially suggested patch

	https://bugs.freedesktop.org/attachment.cgi?id=103315

applies to current (Debian-) systemd HEAD (as of 
debian/215-5-14-g8178d8d) and is working for me

--- old/resolv.conf
+++ /etc/resolv.conf
@@ -5,6 +5,7 @@
 # resolv.conf(5) in a different way, replace the symlink by a
 # static file or a different symlink.
 
+domain lan
 nameserver 10.0.0.1
 nameserver 8.8.8.8
 nameserver 8.8.4.4


$ nslookup redstone
Server:         10.0.0.1
Address:        10.0.0.1#53

Name:   redstone.lan
Address: 10.10.7.0


systemd-networkd configuration:

$ cat /etc/systemd/network/50-br0.netdev 
[NetDev]
Name=br0
Kind=bridge
MACAddress=01:23:45:67:89:AB

$ cat /etc/systemd/network/51-eth0.network 
[Match]
Name=eth0

[Network]
Bridge=br0

$ cat /etc/systemd/network/60-br0.network 
[Match]
Name=br0

[Network]
DHCP=yes


Regards
	Stefan Lippers-Hollmann

-- System Information:
Debian Release: jessie/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.18-rc2-aptosid-amd64 (SMP w/4 CPU cores; PREEMPT)
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages systemd depends on:
ii  acl             2.2.52-2
ii  adduser         3.113+nmu3
ii  initscripts     2.88dsf-57
ii  libacl1         2.2.52-2
ii  libaudit1       1:2.4-1
ii  libblkid1       2.25.2-2
ii  libc6           2.19-12
ii  libcap2         1:2.24-6
ii  libcap2-bin     1:2.24-6
ii  libcryptsetup4  2:1.6.6-3
ii  libgcrypt20     1.6.2-4
ii  libkmod2        18-3
ii  liblzma5        5.1.1alpha+20120614-2
ii  libpam0g        1.1.8-3.1
ii  libselinux1     2.3-2
ii  libsystemd0     215-5
ii  mount           2.25.2-2
ii  sysv-rc         2.88dsf-57
ii  udev            215-5
ii  util-linux      2.25.2-2

Versions of packages systemd recommends:
ii  dbus            1.8.8-2
ii  libpam-systemd  215-5

Versions of packages systemd suggests:
pn  systemd-ui  <none>

-- no debconf information
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.alioth.debian.org/pipermail/pkg-systemd-maintainers/attachments/20141030/4373b2f9/attachment.sig>


More information about the Pkg-systemd-maintainers mailing list