Running VirtualBox VMs as Services in Windows

While I have been tinkering with VirtualBox on Windows hosts, one thing I really wanted to do is to run VMs truely in the background. So that there are no console windows or anything left behind while the VM is running. VirtualBox has a utility called VBoxHeadless which you think would do the trick, but unfortunately it leaves a console window running, as far as I can tell, just to spew out a little information. This is even when you've selected to access the screen via VRDP.

 Well, I just found this handy little tool called VBoxVmService. With this package, you can easily create up to 127 VMs and run them as a service is any flavor of Windows (I tried it with Windows 7 x64). The set up instructions are pretty straight forward, essentially unpack the software somewhere, edit the configuration file to add your VM(s), register VBoxVmService as a Windows service, and start the service.

The only odd thing for me was that initially the start up process complained that it could not find my VMs by name. After digging around a few posts on the VirtualBox forums, I found a workaround that fixed it for me. I had to add VBOX_USER_HOME as a System environment variable, and reboot. After which everything has been running great.

The VMs start up at boot, and I can access them with Windows Remote Desktop Connection client.


Comments:

Welcome to Dayrelax Heat Pump(s).

Posted by Heat Pump on March 04, 2010 at 03:33 PM PST #

Will this not work in Windows? I use this all the time in opensolaris and it works great?

VBoxManage -nologo startvm WinXP --type headless

Posted by Eli Kleinman on March 04, 2010 at 09:22 PM PST #

VBoxManage -nologo startvm WinXP --type headless

Posted by Ed hardy clothing on March 05, 2010 at 10:27 AM PST #

No, I just tried VBoxManage with -nologo option and it does not work. It leaves a console window around when run on a Windows host.

Note that the other nice thing about VBoxVmService, which is the primary feature, is that it can start virtual machines without anyone having to login first.

Posted by Joe Mocker on March 09, 2010 at 12:29 AM PST #

There is also another program which goes a little further then VBoxVMService.

http://code.google.com/p/virtualboxserverservice

Posted by guest on July 06, 2010 at 09:34 PM PDT #

I'm glad you like vboxvmservice. I have just put together a new release today. :-)

Cheers, mattz

Posted by mattz on August 17, 2010 at 06:19 AM PDT #

Post a Comment:
  • HTML Syntax: NOT allowed
About

mock

Search

Top Tags
Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today
Bookmarks
Blogroll

No bookmarks in folder