Tell me more ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

VirtualBox seems to lack the obvious "File -> Open" menu option. Frustrating!

More details...

I recently got a new workstation and I moved my VirtualBox and VMWare Player VMs from the old PC to the new.

The VMWare Player VMs are a snap... you go to "File -> Open a Virtual Machine...", find the .vmx files from the old PC, and voila! It's up and running. All the required files apparently are in the same folder.

With VirtualBox there just doesn't seem to be a way to do that. Looks like VMs are tied to the original host in some magical/invisible way like registry entries, etc.

share|improve this question

7 Answers

up vote 6 down vote accepted

If you want to use an existing virtual hard disk and 'open' it into Virtual Box - you need to go to File > Virtual Media Manager and select 'Add'.

Browse to your existing disk and select ok. This registers a disk with Virtual Box. Now you need to attach this disk to a new or existing VM to actually use it.

share|improve this answer
I created a new machine and then attached the old disk to it... not very intuitive but works for me! Thanks – Alex R Sep 16 '10 at 2:32
1  
When I try that (adding a .vhd created w/ Win7 Virtual PC) I get the error: Failed to open the hard disk V:\ProgramData\VirtualPC\CleanTesting_XP sp1.vhd. Parent medium with UUID {199e419e-a076-d811-81ef-8eeb0865d5ed} of the medium 'V:\ProgramData\VirtualPC\CleanTesting_XP sp1.vhd' is not found in the media registry ('C:\Users\Clay/.VirtualBox\VirtualBox.xml'). – Clay Nichols Dec 14 '10 at 14:46
6  
Add new does not work in VirtualBox 4. Any other solution? – Codism Apr 8 '11 at 21:30
-1 as Codism says, there is no "Add" button. – Mauricio Scheffer Sep 19 '11 at 20:43
1  
For VirtualBox 4 and up (no "Add" button), see Kevin's comment. – Alex Che Aug 1 '12 at 16:06

In the machine folder there is a *.vbox file. Drag it into the VM list in VirtualBox.

share|improve this answer
This worked for me on VirtualBox 4.1.18. Just dropped the virtual machine *.xml file to the VM list. Also needed to add the system's virtual disk back again in the system / storage dialog. – Alex Che Aug 1 '12 at 16:03

I'm not sure I see a problem here. In VirtualBox if you are opening a new VM (one you might have created on a different computer) you use File/Import Appliance and then browse for the file to open. After importation it can be found in the main VM panel.

If you created the VM on the same computer then it's already in the left pane of the main program window.

It may be different from what you're used to but I don't see why it would be frustrating...

share|improve this answer
No luck... "File/Import Appliance" requires an OVF file, which doesn't exist (I guess, I could have created one by doing "Export Appliance" on the old computer, but it's too late now). – Alex R Sep 12 '10 at 15:10
I think the V'Box documentation is pretty clear on this requirement. Unfortunate that you can't go back and redo. What files DO you have available? Maybe there's a way to convert? Or load the old files back on VMware and re-export? – hotei Sep 12 '10 at 16:20

By default, VirtualBox loads its configuration data from the folloing paths:

  • On Windows, this is %HOMEDRIVE%%HOMEPATH%\.VirtualBox; typically something like C:\Documents and Settings\Username\.VirtualBox.
  • On Mac OS X, this is $HOME/Library/VirtualBox.
  • On Unix-like systems (Linux, Solaris), this is $HOME/.VirtualBox.

This means that machines are specific to the logged in user. If you need to set a common place to store machines between different users you can override the default locatiion by setting the VBOX_USER_HOME environment variable. VirtualBox will use the path in this variable as its store for VM configuration data.

See the VirtualBox help topic on VirtualBox configuration data for more information.

share|improve this answer

Importing existing virtual machines from another host into VirtualBox 4 and above on Windows hosts:

  1. Importing the vdi virtual disk:
    1. Go to the menu: File ⇨ Virtual media manager
    2. Drag and drop the [vm_name].vdi into the list
  2. Adding the imported machine to the vbox manager list:
    1. Double-click on the [vm_name].vbox file in the directory of the vm, to add this machine to the vbox manager list
    2. Double-click on the [vm_name].vbox inside the vbox manager list to start the appliance
  3. Sidenotes:
    1. If the VM comes from an older vbox release, you will have an [vm_name].xml inside a sub directory instead of a [vm_name].vbox in the same directory as [vm_name].vdi
    2. Copy the [vm_name].xml into the same directory as the [vm_name].vdi and rename it to [vm_name].vbox
    3. Proceed with step 1.1 or 2.1 depending on the actions you have already taken
share|improve this answer

Regarding errors like this:

Failed to open the hard disk V:\ProgramData\VirtualPC\CleanTesting_XP sp1.vhd. Parent medium with UUID {199e419e-a076-d811-81ef-8eeb0865d5ed} of the medium 'V:\ProgramData\VirtualPC\CleanTesting_XP sp1.vhd' is not found in the media registry ('C:\Users\Clay/.VirtualBox\VirtualBox.xml').

VirtualBox seems to cache the UUID associated with a virtual disk filename. It's not in the file the message says; it must be stored elsewhere. Apparently VirtualBox 4 doesn't support unregister/register disk commands any more.

In the end, I found if I changed the name of the VDI file, then it no longer matches the cached entry and VirtualBox doesn't complain.

share|improve this answer

If you are on a Unix-like computer you can do this:

find /path/to/vms -name "*.vbox" -exec VBoxManage registervm {} \;

You just need to remember to provide the entire path to the .vbox file. If you specify a relative path it will foolishly assume that it is relative to your home folder.

For example, I did this after rebuilding my workstation:

$ find /store/vm -name "*.vbox" -exec VBoxManage registervm {} \;

It found and re-registered all of my virtual machines.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.