Wait for restarted unit to be ready

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm working on some code that handles restarting systemd units via dbus,
and I want to make sure that my logic is correct.

My goal is to restart a unit, and wait for it to be active before my
function returns. Once I've asked the unit to restart, I am watching the
`JobRemoved` signal for messages containing the unit name and handling the
result accordingly. If the signal result is "done" my function returns, and
otherwise it errors. Is this the correct way to wait for unit readiness?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20180504/071a07d0/attachment.html>


[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux