Blarts

If you have to ask you’ll never know

How To Launch a VirtualBox Virtual Machine from a shortcut

Posted by Kim Nguyen on December 3, 2007

One of the things I like about VirtualBox 1.5.0 is the seamless windows mode.  For more information on this you can check out my previous post on VirtualBox 1.5.0. 

The only annoyance I have with this feature is you have to launch the VirtualBox GUI and select your virtual machine.  However VirtualBox does provide a way to launch your Virtual Machine from the command line, this article tells you how to use the command line to create a shortcut or launcher to run your virtual machine without having to run the VirtualBox GUI.

Windows:

Right Click on the desktop and select New / Shortcut.  The following Screen will display:
image

Click the Browse Button and find the “VBoxManage.exe” file located in the directory you installed VirtualBox to.  Just for reference the default installation path is:

C:\Program Files\innotek VirtualBox\VBoxManage.exe

After the quotation marks enter:

startvm <your virtual machine name>

Please note that the virtual machine name is case sensitive.  For my Virtual machine I named it XP and i installed VirtualBox to the default Path so my string looks like this:

“C:\Program Files\innotek VirtualBox\VBoxManage.exe” startvm XP

Once you have your path selected click Next.  Give this shortcut a name and click finish.  When you double-click on your shortcut you will notice a small command prompt screen launch then go away.  In the spirit of making this process even cleaner you can do this:

Right Click on the shortcut and select properties.

When the properties window displays select the Shortcut tab and then change the run option from windowed to minimized.  Here’s a screen shot of the window:

image

 

Ubuntu

Right Click on your desktop and select Create Launcher

When the Create Launcher window displays name your launcher and in the command field type in:

VBoxManage startvm <your virtual machine name>

Again the Virtual Machine name is case sensitive.  Below is a screen shot of the my window:

Screenshot-Create Launcher

If you want you can click on the No icon button and select an icon for the launcher. 

 

14 Responses to “How To Launch a VirtualBox Virtual Machine from a shortcut”

  1. Adri said

    Thanks for your explanation! It really helped me out. Starting Windows under Ubuntu is now as simple as one click!

  2. josh said

    thanks for the howto! works perfectly and simple too =o)

  3. replier said

    @Adri: i would say simple as a double-click

  4. Thanks a bunch! Saved me the trouble of looking through documentation :)

  5. carby delrey said

    many thanks, this made my system easier to use

  6. Guardian said

    Works Great on Sidux as well.
    http://www.sidux.com

  7. Thank you! :) I`ve explained Ubuntu a while ago, but now I switched to Mac and this is the only system not mentioned here :-) Can you help me?

    thx Vita

  8. Hehe, now I know… I`ve just created an Automator task. There is a option “Shell script” and the whole thing can be saved as an Application.

  9. murdockpt said

    haha! =D thanks! :)

  10. clysher said

    Sorry, but in Ubuntu 8.10 creating the shortcut launches nothing, it doesn’t do anything at all actually. The only difference is that my VM is called Windows XP, not just XP, is this the problem? Or do I have some magical problem.

    • Kim Nguyen said

      The reason why nothing happens is you have the virtual machine name wrong. I think what you need to repalce the “XP” with the name of your virtual machine. so in your case you would type in “VBoxManage startvm Windows XP”. if that doesn’t work the best bet is to type the command into the command line and play around with the VM name until you get it and once you do copy it to into the launcher.

  11. wes Sole said

    Thank you. Works great.

  12. [...] Via | Blarts [...]

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>