libvirt-guests: Fix dependency ordering in service file

After some debugging and discussion with systemd team it turns out we
are misusing the ordering in libvirt-guests.service.  That happened
because we want to support both monolithic and modular daemon setups and
on top of that we also want to support socket activation and services
without socket activation.  Unfortunately this is impossible to express
in the unit file because of how transactions are handled in systemd when
dependencies are resolved and multiple actions (jobs) are queued.  For
explanation from Michal Sekletar see comment #7 in the BZ this patch is
fixing:

https://bugzilla.redhat.com/show_bug.cgi?id=1964855#c7

In order to support all the scenarios this patch also amends the
manpages so that users that are changing the default can also read how
to correct the dependency ordering in libvirt-guests unit file.

Ideally we would also keep the existing configuration during upgrade,
but due to our huge support matrix this seems hardly feasible as it
could introduce even more problems.

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Martin Kletzander
2022-09-26 13:04:48 +02:00
parent e9fd6de8fc
commit 59d30adacd
7 changed files with 84 additions and 6 deletions
-6
View File
@@ -9,12 +9,6 @@ After=virtlxcd.socket
After=virtvboxd.socket
After=virtvzd.socket
After=virtxend.socket
After=libvirtd.service
After=virtqemud.service
After=virtlxcd.service
After=virtvboxd.service
After=virtvzd.service
After=virtxend.service
After=virt-guest-shutdown.target
Documentation=man:libvirt-guests(8)
Documentation=https://libvirt.org