You are not logged in.

#1 2013-01-05 11:25:18

hueck
Member
Registered: 2011-09-15
Posts: 12

VboxHeadless wont start via systemd

Already tried this Topic but doesn't solved it: https://bbs.archlinux.org/viewtopic.php?id=147591


I have placed a file called vbox.service under /lib/systemd/system/vbox.service with the following content

[Unit]
Description=Virtualbox Headless VM

[Service]
ExecStart=/usr/bin/VBoxHeadless --startvm 4decf7c1-7eda-461c-92aa-835d2405a22e
ExecStop=/usr/bin/VBoxManage controlvm 4decf7c1-7eda-461c-92aa-835d2405a22e poweroff
User=my_user

[Install]
WantedBy=muti-user.target

If I start and stop it via

sudo systemctl start vbox and sudo systemctl stop vbox, everything works fine

Then i entered the following:

sudo systemctl enable vbox, but it wont start at boot

Here is the output

sudo systemctl status vbox
vbox.service - Virtualbox Headless VM
	  Loaded: loaded (/usr/lib/systemd/system/vbox.service; enabled)
	  Active: inactive (dead)
	  CGroup: name=systemd:/system/vbox.service

Jan 05 02:38:59 exia pulseaudio[1428]: [pulseaudio] main.c: Daemon startup failed.
Jan 05 02:40:08 exia systemd[1]: Started Virtualbox Headless VM.
Jan 05 02:42:02 exia systemd[1]: Stopping Virtualbox Headless VM...
Jan 05 02:42:02 exia VBoxManage[1546]: 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Jan 05 02:42:02 exia VBoxHeadless[1375]: Oracle VM VirtualBox Headless Interface 4.2.6_OSE
Jan 05 02:42:02 exia VBoxHeadless[1375]: (C) 2008-2012 Oracle Corporation
Jan 05 02:42:02 exia VBoxHeadless[1375]: All rights reserved.
Jan 05 02:42:02 exia VBoxHeadless[1375]: VRDE server is listening on port 3389.
Jan 05 02:42:02 exia VBoxHeadless[1375]: VRDE server is inactive.
Jan 05 02:42:02 exia systemd[1]: Stopped Virtualbox Headless VM.

/usr/bin/VBoxHeadless --startvm 4decf7c1-7eda-461c-92aa-835d2405a22e works fine

Any ideas, though?

Offline

#2 2013-01-05 12:08:34

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,837

Re: VboxHeadless wont start via systemd

Not a solution, just some general tips:

- custom service files should be placed in /etc/systemd/system
- the path for package-installed service files is /usr/lib/systemd/system, not /lib/systemd/system.

Last edited by tomk (2013-01-05 13:31:10)

Offline

#3 2013-01-05 12:48:33

graysky
Member
From: /run/user/1000
Registered: 2008-12-01
Posts: 8,439
Website

Re: VboxHeadless wont start via systemd

Does not solve the systemd problem but: https://aur.archlinux.org/packages/vbox-headless-daemon


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

Board footer

Powered by FluxBB