FS#61738 - [openconnect] Unit dbus-org.freedesktop.resolve1.service not found.
Attached to Project:
Arch Linux
Opened by f (bakgwailo) - Wednesday, 13 February 2019, 01:22 GMT
Last edited by freswa (frederik) - Saturday, 26 September 2020, 22:56 GMT
Opened by f (bakgwailo) - Wednesday, 13 February 2019, 01:22 GMT
Last edited by freswa (frederik) - Saturday, 26 September 2020, 22:56 GMT
|
Details
Description:
Noticed after updating my system today and rebooting my openconnect VPN was no longer working. Further investigation shows systemd-resolve status fails with this error message: status: resolve call failed: Unit dbus-org.freedesktop.resolve1.service not found. Additional info: * package version(s) systemd 240.95-1 Normal/up to date Arch, no testing repos enabled. Steps to reproduce: Run systemd-resolve (or I guess anything else that depends on it like openconnect). |
This task depends upon
Closed by freswa (frederik)
Saturday, 26 September 2020, 22:56 GMT
Reason for closing: Fixed
Additional comments about closing: openconnect 1:0.5.3.r462.r78-1
Saturday, 26 September 2020, 22:56 GMT
Reason for closing: Fixed
Additional comments about closing: openconnect 1:0.5.3.r462.r78-1
as used by vpnc 1:0.5.3.r454.r67-1 needs adjustment although that seems to be a separate issue to why systemd-resolve was disabled on upgrade.
Edit:
changed line number from 131 to 119
- Error: any valid prefix is expected rather than "dev"
- RTNETLINK answers: File exists (after a Ctrl-C and 2nd attempt to openconnect)
I still get the "dev" error, but by checking my ifconfig output after vpn, I could put the real nameserver in /etc/resolv.conf and all is working (it was some 192.168.foo after connecting).
$ pacman -Qo /usr/lib/systemd/system/systemd-resolved.service
/usr/lib/systemd/system/systemd-resolved.service is owned by systemd 241.7-2
You uninstalled all of systemd?
I uninstalled *systemd-resolvconf*. I prefer non-systemd resolvconf. I tried installing it to see if it would fix my VPN DNS. The error message "status: resolve call failed: Unit dbus-org.freedesktop.resolve1.service not found." went away. But it still didn't work. Once I uninstalled systemd-resolvconf, reinstalled resolvconf and downgraded to 240.95 from 241.7 my vpn started working again.
resolvconf either version will not be used in this case.
change line /etc/vpnc/vpnc-script line 121 from
RESOLVEDENABLED=1
to
RESOLVEDENABLED=0
it will rely on either a working resolvconf (i.e. openresolv + glibc resolver or systemd-resolved + systemd-resolvconf) or /etc/resolv.conf being the actual file used used by the glibc resolver.
before it relied on systemd-resolved, did not work with the glibc resolver and would not use resolvconf
---
vpnc-script | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/vpnc-script b/vpnc-script
index 6a55546..b00dbb9 100755
--- a/vpnc-script
+++ b/vpnc-script
@@ -116,8 +116,7 @@ else
ifconfig_syntax_ptpv6=""
fi
-grep ^hosts /etc/nsswitch.conf|grep resolve >/dev/null 2>&1
-if [ $? = 0 ];then
+if grep -qs '^hosts.*resolve' /etc/nsswitch.conf && (command -v systemd-resolve && systemd-resolve --status) >/dev/null 2>&1; then
RESOLVEDENABLED=1
else
RESOLVEDENABLED=0
--
That did solve the issue for me when applied locally. I also use openconnect, but do not want to use systemd-resolved.
The patch posted by a10b works, though I still get the error 'Error: any valid prefix is expected rather than "dev".' This is with systemd-resolved disabled/stopped, so that's nice. This is equivalent behavior to when I had systemd-resolved enabled (still go the 'dev' error).
Who is suggesting you must use systemd-resolve? Who is suggesting it is not a bug that needs to be fixed?
Unfortunately my problem ist not with vpnc but NetworkManager, but otherwise the same. Even though it is configured to update resolv.conf directly (main.dns=default), it keeps spamming my log files with requests like this.
Mar 25 18:28:04 BachsauDesk dbus-daemon[614]: [system] Activating via systemd: service name='org.freedesktop.resolve1' unit='dbus-org.freedesktop.resolve1.service' requested by ':1.15' (uid=0 pid=616 comm="/usr/bin/NetworkManager --no-daemon ")
Mar 25 18:28:04 BachsauDesk dbus-daemon[614]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.resolve1.service': Unit dbus-org.freedesktop.resolve1.service not found.
I never implied that, calm down.