[systemd-devel] The dependencies between systemd-resolved and dbus.socket
Jeremy Su
os369510 at gmail.com
Fri Apr 11 13:13:48 UTC 2025
Hi,
I meet a problem that systemd-resolved is not able to resolve the DNS.
systemd-resolved[1237]: sd-bus: starting bus bus-api-resolve by connecting
to /run/dbus/system_bus_socket...
systemd-resolved[1237]: Added inotify watch for /run on bus
bus-api-resolve: 2
systemd-resolved[1237]: Added inotify watch for /run/dbus on bus
bus-api-resolve: 3
systemd-resolved[1237]: Added inotify watch for /run/dbus/system_bus_socket
on bus bus-api-resolve: -1
systemd-resolved[1237]: sd-bus: starting bus bus-api-resolve by connecting
to /run/dbus/system_bus_socket...
It seems to me that the systemd-resolved doesn't able to access
/run/dbus/system_bus_socket. FWIU, the /run/dbus/system_bus_socket is
created by dbus.socket.
However, the dependencies seem like:
systemd-resolved -> sysinit.target -> dbus.socket.
according to:
$ systemctl show dbus.socket | grep -i after
After=-.mount sysinit.target system.slice
$ systemctl show systemd-resolved | grep -i before
Before=initrd-switch-root.target shutdown.target nss-lookup.target
network.target sysinit.target
If I set "Wants=dbus.socket" "Before=dbus.socket" in systemd-resolved, then
it'll introduce circular dependency.
It seems weird to me, does anyone let me know if I missing anything?
--
Sincerely,
Jeremy Su
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20250411/7af535fb/attachment.htm>
More information about the systemd-devel
mailing list