VM fails to start using VBoxManage, starts from VBoxHeadless

Discussions related to using VirtualBox on Linux hosts.
Post Reply
harahauk
Posts: 5
Joined: 13. May 2009, 23:17
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win2008

VM fails to start using VBoxManage, starts from VBoxHeadless

Post by harahauk »

First off: Hi all, I'm new to this forums and I love virtualbox<3
Maybe someone could help me with my testserver stalling?

My problem is that my virtual machine simply will not start using the VBoxManage command.
I try:

Code: Select all

harahauk@spiderpig:~$ VBoxManage startvm 4aebbea6-97a4-4163-bb8d-dc800fa954b3
Where that long string of numbers and chars is my VM uid, I've also tried using the name.

With result:

Code: Select all

VirtualBox Command Line Management Interface Version 2.2.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.

Waiting for the remote session to open...
ERROR: Virtual machine 'AXION' has terminated unexpectedly during startup
Details: code NS_ERROR_FAILURE (0x80004005), component Machine, interface IMachine, callee <NULL>
Hovever:

Code: Select all

harahauk@spiderpig:~$ VBoxHeadless -s "AXION"
Results in a VM i can remote desktop tom everything looks fine here, however it takes up one terminal and I really want to use the software as it was intended.

Should I post my .xml's?

I'm running VirtualBox 2.2 on Ubuntu Jaunty Server.
My hardware has no support for virtualization extentions.
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by TerryE »

If you want to run a graphics based VM then you have two options: the first is to use the VBoxHeadless command and RDP as the transport. The second is to use the QT based interface, and this need X access. If you do a $ gedit & and this barfs then you haven't got the correct X authorisations set up. This isn't a VBox issue, so solve this for gedit using your OS forums for help before trying to get VBoxManage startvm to work.

I am also not sure how well the GA seamless desktop will work in this scenario. Not at all, I suspect.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
harahauk
Posts: 5
Joined: 13. May 2009, 23:17
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win2008

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by harahauk »

Thanks for your answer.
I dont really want to use any graphical features on the guest from the host.
All i want is the VM to start, the graphics can go to /dev/null, I just want to be able to use services running on the guest througn nat port forwarding.

I dont use a gui on my host, so I thought VBoxManage or VboxHeadless was my savior
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by Sasquatch »

VBoxManage calls the GUI part, VBoxHeadless doesn't. So what you need, is run VBoxHeadless with an '&' at the end, so it will run as a background process.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
harahauk
Posts: 5
Joined: 13. May 2009, 23:17
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win2008

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by harahauk »

thanks, that solution will have to do =)
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by TerryE »

harahauk wrote:$ VBoxHeadless -s "AXION" -- everything looks fine here, however it takes up one terminal and I really want to use the software as it was intended.
Sasquatch wrote:what you need, is run VBoxHeadless with an '&' at the end, so it will run as a background process.
Sometimes you forget just how litte users know about their OSs and miss the bleeding obvious :lol:
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
harahauk
Posts: 5
Joined: 13. May 2009, 23:17
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win2008

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by harahauk »

Well thanks for pointing that out, real friendly.
Fact is I already knew how to do that, but it really was not what i wanted cause even though i can still type in that terminal the VM will die if its closed. Therefore I though maybe one of the friendly members of this community had encountered similar difficulties.
I really was hoping to run the VM through a deamon or something, not keep an terminal open that i risk closing by accident, thereby isnta-killing the VM.

I guess I'm kinda spoiled by VMware server.. If only it had the performance of VB..
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by TerryE »

harahauk, sorry I wasn't trying to be sarcastic. I was just stating a truth, and it was really a side comment from me to a colleague sasquatch. What you missed was Linux 101 — that is novice Unix stuff. When you want to run a process in the background rather that the foreground then you let the shell know by sticking an & at the end of the command line. I've been in and out of Unix for 25 years and this has been the case all that time.

If you don't want the VM to die when your session drops use nohup or at now. Again basic Unix stuff.

The VBoxHeadless command is designed to be background friendly. You control the background VM with the VBoxManage controlvm command.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
slanbarn
Posts: 28
Joined: 11. Feb 2009, 10:22
Primary OS: Debian Lenny
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: WinXP, etc.
Location: Sweden

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by slanbarn »

Hello!

What happs if you try VBoxManage startvm <name of vm> -type vrdp

does that dies when you close your terminal? Cant try right now my self, only do this via putty and terminal server client, and have a ssh tunnel usign putty, so closing putty, brings down my ssh tunnel, so the connection with ts-client dies to...

I would think tho that previous command would let you VM live if your terminal dies...
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by TerryE »

slanbarn wrote:What happens if you try VBoxManage startvm <name of vm> -type vrdp Does that die when you close your terminal?
Yes, you are correct. The VBoxManage child process is detached from the parent shell session, so you can log out of SSH. This is a simpler approach for none-experts. Thank-you.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
harahauk
Posts: 5
Joined: 13. May 2009, 23:17
Primary OS: Ubuntu other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win2008

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by harahauk »

slanbarn wrote:Hello!
What happs if you try VBoxManage startvm <name of vm> -type vrdp
Exellent! Thanks!
Terry I'm no *nix expert as of yet and your suggestion with nohup was also helpful.
This was exactly what I wanted, thanks again slanbarn =)
slanbarn
Posts: 28
Joined: 11. Feb 2009, 10:22
Primary OS: Debian Lenny
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: WinXP, etc.
Location: Sweden

Re: VM fails to start using VBoxManage, starts from VBoxHeadless

Post by slanbarn »

Glad to help:)
Post Reply