Hello, I'd like to ask your opinion on the following situation. B.service exposes its API through D-Bus. A.service uses this API and thus it has a dependency on B.service. This is implicit though -- and we're happy we can rely on D-Bus activation and needn't to list all dependencies explicitly.
As it comes, A.service needs B.service for proper termination. During the shutdown transaction there is unspecified ordering of the two (since the dependency is implicit only) and B.service is stopped before A.service. A.service would attempt to D-Bus-activate B.service but that is rejected because dbus-daemon will eventually stop too. Note this doesn't mean dbus-daemon is already handling SIGTERM, it's because a dbus-daemon stop job is pending [1]. A.service may thus cannot terminate properly. I know this could be circumvented by explicitly specifying After=b.service for the A.service but denies the elegance of the lazy (implicit) activation. Are there any better ways how to deal with this? Thanks, Michal Koutný P.S. FTR, in my case A.service=libvirtd.service and B.service=systemd-machined.service. [1] https://github.com/systemd/systemd/blob/master/src/core/dbus.c#L169
signature.asc
Description: OpenPGP digital signature
_______________________________________________ systemd-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/systemd-devel
