On 29/01/2025 01:39, Greg Wooledge wrote:
The question is about this dangling symlink:

hobbit:/etc/systemd/system$ ls -l dbus-org.freedesktop.timesync1.service
lrwxrwxrwx 1 root root 45 Feb 17  2024 dbus-org.freedesktop.timesync1.service 
-> /lib/systemd/system/systemd-timesyncd.service
[...]
I'm unclear on exactly how this symlink gets created.

My guess, it is effect of

    Alias=dbus-org.freedesktop.timesync1.service

from /usr/lib/systemd/system/systemd-timesyncd.service and

deb-systemd-helper enable 'systemd-timesyncd.service' >/dev/null || true

from systemd-timesyncd.postinst. I am not familiar with systemd-related machinery in package scripts. Perhaps systemd-timesyncd.prerm should call

    deb-systemd-helper disable 'systemd-timesyncd.service'

to remove the synlink on "remove" dpkg action. Now service is likely disabled on "purge" from postrm, but systemd-timesyncd.service should be removed at this point, so perhaps there is no chance to find the alias.

I would report a bug. The maintainers of systemd package should know better purpose and effects of helper scripts.

Reply via email to