[libvirt] [PATCH] util: swap After/Before clauses in virSystemdCreateMachine

Daniel P. Berrange berrange at redhat.com
Wed Jun 29 10:37:41 UTC 2016


On Wed, Jun 29, 2016 at 03:15:44AM -0700, Quentin Machu wrote:
> An unexpected behavior in systemd has been introduced between the versions
> 225 and 229: when non-existing units are specified in After/Before clauses,
> systemd fails if the After clause is listed first. What is expected is that
> systemd simply ignores these clauses. Because the After clause is specified
> before the Before clause in virSystemdCreateMachine and because libvirt
> does not tolerate missing the systemd-machined registration, it leads to
> fatal boot failures, whereas instances could start properly without these
> units - only the shutdown workflow could be affected.

IMHO the real bug here is the fact that you are missing the
libvirtd.service unit file referenced by the After clause.
That missing unit file is what should be fixed.

The order of properties should have no effect at all - any
functional difference in After/Before and Before/After is
likely a bug in systemd that should be fixed there, as there
is no defined requirement from systemd to set properties in
any particular order. If this change in ordering has an effect
for you, I think it is likely just blind luck.

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|




More information about the libvir-list mailing list