Package: anacron Version: 2.3-34 Followup-For: Bug #1019554 Dear Maintainer,
It seems that those symlinks(/etc/systemd/system/multi-user.target.wants/anacron.service and /etc/systemd/system/timers.target.wants/anacron.timer) are not "dangling". My testing in a debootstrap sid shows that installing anacron=2.3-32 will create those symlinks and purging the anaron package will remove those symlinks. It seems that those symlinks are handled by deb-systemd-helper in anacron.post{inst,rm}: segment in anacron.postinst: # Automatically added by dh_installsystemd/13.9.1 if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-decon figure" ] || [ "$1" = "abort-remove" ] ; then # This will only remove masks created by d-s-h on package removal. deb-systemd-helper unmask 'anacron.service' >/dev/null || true # was-enabled defaults to true, so new installations run enable. if deb-systemd-helper --quiet was-enabled 'anacron.service'; then # Enables the unit on first installation, creates new # symlinks on upgrades if the unit file has changed. deb-systemd-helper enable 'anacron.service' >/dev/null || true else # Update the statefile to add new symlinks (if any), which need to be # cleaned up on purge. Also remove old symlinks. deb-systemd-helper update-state 'anacron.service' >/dev/null || true fi fi # End automatically added section segment in anacron.postrm: # Automatically added by dh_installsystemd/13.9.1 if [ "$1" = "remove" ]; then if [ -x "/usr/bin/deb-systemd-helper" ]; then deb-systemd-helper mask 'anacron.service' 'anacron.timer' >/dev/null || true fi fi if [ "$1" = "purge" ]; then if [ -x "/usr/bin/deb-systemd-helper" ]; then deb-systemd-helper purge 'anacron.service' 'anacron.timer' >/dev/null || true deb-systemd-helper unmask 'anacron.service' 'anacron.timer' >/dev/null || true fi fi # End automatically added section deb-systemd-helper is included in the init-system-helpers package, which is a essential package meaning it will be installed in all Debian system. So those symlinks will be purged when the anacron package is purged. On Mon, 19 Sep 2022 12:59:59 +0000 Lance Lin <lqi...@protonmail.com> wrote: > # Close bug #993348 > rm /etc/systemd/system/multi-user.target.wants/anacron.service > rm /etc/systemd/system/timers.target.wants/anacron.timer And concerning your proposed changes, it seems to me that if anacron.service or anacron.timer were disabled, these rm will cause anacron.postrm exited with error. So I think there is no need to manually handle those symlinks and anacron.postrm should be reverted to the 2.3-32 revision. -- System Information: Debian Release: bookworm/sid APT prefers unstable-debug APT policy: (500, 'unstable-debug'), (500, 'unstable') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 5.19.0-1-amd64 (SMP w/2 CPU threads; PREEMPT) Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages anacron depends on: ii libc6 2.34-8 ii sysvinit-utils [lsb-base] 3.05-5 Versions of packages anacron recommends: ii cron [cron-daemon] 3.0pl1-149 Versions of packages anacron suggests: ii exim4-daemon-light [mail-transport-agent] 4.96-4 ii powermgmt-base 1.37 ii rsyslog [system-log-daemon] 8.2208.0-1 -- no debconf information