Usually, when I remove a lot of apps, I see the situation of needing to disable all their units one by one to prevent systemd from trying to start them on every reboot. Would be nice if systemctl could have an option to remove all now missing units (that are now missing links in /etc then) with only one command invocation Thanks
Humm, your packaging system is quite broken if it leaves those dead links around... I think this command should be enough for what you are trying to do, no? find /etc/systemd/system -type l -exec test ! -e {} \; -delete I am not convinced that we need explicit functionality for this in systemd, especially since this is brokeness in your package management scripts I think.
Not sure what are we supposed to do downstream. I guess, running "systemctl remove" for all provided units when the package is removed?
(In reply to comment #2) > Not sure what are we supposed to do downstream. I guess, running "systemctl > remove" for all provided units when the package is removed? There is no "remove". Use "systemctl disable" and then "systemctl stop" for all units your package installed.
(Just to provide some context: for RPM we do this with these macros: http://cgit.freedesktop.org/systemd/systemd/tree/src/core/macros.systemd.in )
Sorry for the "remove", was probably due replying to this after hours of work :(
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.