![]() But if the VM doesn’t shut down in response to the acpipowerbutton, the VM service just stays up. KillMode=None/TimeoutStopSec does get the acpipowerbutton to the VM, and if it does shut down cleanly as a result, everything is fine. For more information on using systemd, see the general Arch Linux Wiki Page. You can continue to manage your VMs using the GUI interface if you choose. You may need to turn off 3D video features for your VM to run in headless mode. After your computer starts up, you can use ‘systemctl –failed’ to make sure everything went smoothly. To enable one or more VMs at boot, enter: #systemctl enable ‘systemctl start’ to immediately start the VM. ![]() You can also replace ‘savestate’ in ‘ExecStop=’ with ‘poweroff’ or ‘acpipowerbutton’ to hard-stop the VM, or ask for a clean shut-down, respectively. ![]() If you need to delay the start of the VMs until after your network is started or a network share is mounted, locate the service you want to wait for using ‘systemctl’ and then substitute the service, mount, or network behind ‘After=’. Make sure that the user is in the vboxusers group. Replace the user after user= with the username you want to run the VMs. ![]() Add a file called in /etc/systemd/system/.ĭescription=VBox Virtual Machine %i ServiceĮxecStop=/usr/bin/VBoxManage controlvm %i savestate This Arch Linux wiki page contains a sample service file that you can use to start VirtualBoxVMs in a headless mode. If you are looking to start your VirtualBox VMs automatically on boot using systemd look no further.
0 Comments
Leave a Reply. |