[systemd-devel] Reliable way to finish system units before termination through systemd shutdown / reboot routines

Andrei Borzenkov arvidjaar at gmail.com
Sat Sep 2 15:11:22 UTC 2017


15.08.2017 17:25, Reiner Wenke пишет:
> Hello,
> 
> I have running some virtualbox instances under systemd control and use vboxautostart-service
> for starting and stopping (saving). This is running on Centos7
> As long as I use systemctl stop vboxautostart-service for termination, everything is fine, 
> but it takes some time for completion.
> 
> If I shutdown or reboot the host system, then I get a premature kill of all running instances,
> most likely through the systemd reboot / shutdown routines .
> I tried some configuration changes, but nothing worked for me.
> 
> Is there a reliable way to avoid this behavior?
> 

It really depends on how VB starts services. My best guess (from
touching this in the past) is: when stopping VB startup script sends
request to each VM and exits. For systemd it means VB service has
completed and it cleans up by killing all remaining processes. You need
to debug what happens - then someone may come up with suggestion how to
fix it.


More information about the systemd-devel mailing list