FS#54796 - [systemd] missing dbus-org.freedesktop.resolve1.service when using systemd-resolve

Attached to Project: Arch Linux
Opened by Shane (buffalo) - Friday, 14 July 2017, 03:13 GMT
Last edited by Christian Hesse (eworm) - Monday, 24 July 2017, 15:37 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Christian Hesse (eworm)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 3
Private No

Details

Description: After updating to systemd233.75, I get an error when I try to use systemd-resolved. I ran into the issue trying to start openvpn, but I found that basically any command using systemd-resolve gives an error. Here are a few commands I ran:

20:19 ~ $ systemd-resolve status
status: resolve call failed: Unit dbus-org.freedesktop.resolve1.service not found.
20:20 ~ $ systemd-resolve yahoo.com
yahoo.com: resolve call failed: Unit dbus-org.freedesktop.resolve1.service not found.
20:20 ~ $ journalctl --since "1 min ago"
-- Logs begin at Sun 2016-05-15 13:50:46 CDT, end at Mon 2017-07-10 20:20:10 CDT. --
Jul 10 20:20:06 leaf dbus[406]: [system] Activating via systemd: service name='org.freedesktop.resolve1' unit='dbus-org.freedesktop.resolve1.service'
Jul 10 20:20:06 leaf dbus[406]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.resolve1.service': Unit dbus-org.freedesktop.resolve1.service not found.
Jul 10 20:20:10 leaf dbus[406]: [system] Activating via systemd: service name='org.freedesktop.resolve1' unit='dbus-org.freedesktop.resolve1.service'
Jul 10 20:20:10 leaf dbus[406]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.resolve1.service': Unit dbus-org.freedesktop.resolve1.service not found.


This happens on both my laptop and desktop running Arch. I downgraded both systems and then systemd-resolve started to work as expected on both systems.

I noticed that in the package systemd 233.75-3, the directory /etc/systemd/system/ is empty.
In the systemd 233-7 package, /etc/systemd/system/ contains several files ending in .service, including dbus-org.freedesktop.resolve1.service. I'm guessing that empty directory is the issue.


Additional info:
* package version(s)
233.75-3 - bad
233-7 - no issue
* config and/or log files etc.


Steps to reproduce:
Update systemd to 233.75-3. Run "systemd-resolve --status".
This task depends upon

Closed by  Christian Hesse (eworm)
Monday, 24 July 2017, 15:37 GMT
Reason for closing:  Duplicate
Additional comments about closing:   FS#54718 
Comment by Shane (buffalo) - Friday, 14 July 2017, 17:48 GMT
I think I have figured out how to fix this issue. On an affected machine, I copied dbus-org.freedesktop.resolve1.service from an older version of the systemd package into /etc/systemd/system/. Then systemd-resolve started to work as expected.

17:36 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ systemd-resolve --status
Failed to get global data: Unit dbus-org.freedesktop.resolve1.service not found.
17:36 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ systemd-resolve x.org
x.org: resolve call failed: Unit dbus-org.freedesktop.resolve1.service not found.
17:36 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ ls
dbus-org.freedesktop.resolve1.service
17:36 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ sudo cp dbus-org.freedesktop.resolve1.service /etc/systemd/system/
[sudo] password for user:
17:36 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ systemd-resolve --status
Global
DNS Servers: 169.10.8.27
169.10.8.26
169.10.8.4
169.10.8.5
DNS Domain: usac.mmm.com
DNSSEC NTA: 10.in-addr.arpa
16.172.in-addr.arpa
168.192.in-addr.arpa
17.172.in-addr.arpa
18.172.in-addr.arpa
19.172.in-addr.arpa
20.172.in-addr.arpa
21.172.in-addr.arpa
22.172.in-addr.arpa
23.172.in-addr.arpa
24.172.in-addr.arpa
25.172.in-addr.arpa
26.172.in-addr.arpa
27.172.in-addr.arpa
28.172.in-addr.arpa
29.172.in-addr.arpa
30.172.in-addr.arpa
31.172.in-addr.arpa
corp
d.f.ip6.arpa
home
internal
intranet
lan
local
private
test

Link 2 (enp0s3)
Current Scopes: LLMNR/IPv4 LLMNR/IPv6
LLMNR setting: yes
MulticastDNS setting: no
DNSSEC setting: no
DNSSEC supported: no
17:37 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ systemd-resolve x.org
x.org: 131.252.210.176

-- Information acquired via protocol DNS in 143.1ms.
-- Data is authenticated: no
17:37 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $
17:38 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $ pacman -Qii systemd
Name : systemd
Version : 233.75-3
Description : system and service manager
Architecture : x86_64
URL : https://www.github.com/systemd/systemd
Licenses : GPL2 LGPL2.1
... omitted ...

17:38 ~/Downloads/systemd-233-6-x86_64/etc/systemd/system $
Comment by Shane (buffalo) - Saturday, 15 July 2017, 13:49 GMT
Update: maybe that should actually be a symlink that goes in /etc/systemd/system/ instead of an actual file. Running this command just fixed it on my desktop after updating systemd to 233.75-3:


/etc/systemd/system $
/etc/systemd/system $ sudo ln -s /usr/lib/systemd/system/systemd-resolved.service dbus-org.freedesktop.resolve1.service
/etc/systemd/system $
Comment by krukai (krukai) - Monday, 24 July 2017, 15:17 GMT
In /usr/lib/systemd/system I found the following symlinks:

dbus-org.freedesktop.hostname1.service -> systemd-hostnamed.service
dbus-org.freedesktop.import1.service -> systemd-importd.service
dbus-org.freedesktop.locale1.service -> systemd-localed.service
dbus-org.freedesktop.login1.service -> systemd-logind.service
dbus-org.freedesktop.machine1.service -> systemd-machined.service
dbus-org.freedesktop.network1.service -> systemd-networkd.service
dbus-org.freedesktop.timedate1.service -> systemd-timedated.service

So apart from resolve1 being missing, it seems to me that the symlink should not be added to /etc/systemd/system as described above, but rather /usr/lib/systemd/system.

I ran pacman -Fs dbus-org.freedesktop.network1.service before syncing the file database with the following result:
core/systemd 233-7
usr/lib/systemd/system/dbus-org.freedesktop.network1.service

However, after running pacman -Fy I get no result anymore.
In systemd 234.11-1 (testing), the file is still missing.

This means that somewhere between systemd 233-7 and 233.75-3 the file went missing.
Comment by Christian Hesse (eworm) - Monday, 24 July 2017, 15:36 GMT
Upstream moved the file from /usr to /etc, we remove it when building the package.
This file is supposed to be linked by systemctl when systemd-resolved.service is enabled. Package systemd 233.75-3 has code in install script to reenable systemd-resolved.service (and hence recreate the symlink) when required.

Loading...