systemd: cleanup removed services

Fixes QubesOS/qubes-issues#2192
This commit is contained in:
Marek Marczykowski-Górecki 2016-07-25 13:51:20 +02:00
parent 979e2d2bf8
commit 90be5be630
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724
2 changed files with 16 additions and 0 deletions

View File

@ -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

View File

@ -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