From 90be5be6302f7c84d22215d7659022e246665f1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Mon, 25 Jul 2016 13:51:20 +0200 Subject: [PATCH] systemd: cleanup removed services Fixes QubesOS/qubes-issues#2192 --- debian/qubes-core-agent.postinst | 8 ++++++++ rpm_spec/core-vm.spec | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/debian/qubes-core-agent.postinst b/debian/qubes-core-agent.postinst index de55576..e5d06d8 100755 --- a/debian/qubes-core-agent.postinst +++ b/debian/qubes-core-agent.postinst @@ -128,6 +128,14 @@ case "${1}" in rm -f /lib/firmware/updates fi + # remove old symlinks + if [ -L /etc/systemd/system/sysinit.target.wants/qubes-random-seed.service ]; then + systemctl --no-reload disable qubes-random-seed.service >/dev/null + fi + if [ -L /etc/systemd/system/sysinit.target.wants/qubes-mount-home.service ]; then + systemctl --no-reload disable qubes-mount-home.service >/dev/null + fi + if ! dpkg-statoverride --list /var/lib/qubes/dom0-updates >/dev/null 2>&1; then dpkg-statoverride --update --add user user 775 /var/lib/qubes/dom0-updates fi diff --git a/rpm_spec/core-vm.spec b/rpm_spec/core-vm.spec index 25f1412..38268b3 100644 --- a/rpm_spec/core-vm.spec +++ b/rpm_spec/core-vm.spec @@ -631,6 +631,14 @@ grep '^[[:space:]]*[^#;]' /lib/systemd/system-preset/75-qubes-vm.preset | while esac done +# remove old symlinks +if [ -L /etc/systemd/system/sysinit.target.wants/qubes-random-seed.service ]; then + systemctl --no-reload disable qubes-random-seed.service >/dev/null +fi +if [ -L /etc/systemd/system/sysinit.target.wants/qubes-mount-home.service ]; then + systemctl --no-reload disable qubes-mount-home.service >/dev/null +fi + /bin/systemctl daemon-reload exit 0