VirtualBox 4 configuration files

For those that are long time users of VirtualBox you'll notice a few changes with version 4.0. One of those changes is the location of VirtualBox configuration files for vm's, and where virtual disk and snapshot files are saved too. Here's what we've done:

When creating new vm's in VirtualBox 4.0 we've moved all the info about a vm into a subfolder. This makes it easier to, say, tar up the folder contents in order to share the vm with your friends without going through the export/import process. And because the saved state and snapshot files are under the same subfolder, then you can even move suspended vm's, and those with multi-generational snapshots too.

Here's a summary of where stuff has moved to:

Before 4.0 4.0 or above
Default machines folder $HOME/.VirtualBox/Machines $HOME/VirtualBox VMs
Default disk image location $HOME/.VirtualBox/HardDisks In each machine's folder
Machine settings file extension .xml .vbox

Another benefit of these changes is that we associate files with the .vbox extension with VirtualBox. So you can launch vm's by double clicking on the .vbox file, or create an Alias or Shortcut to a vm when you right click in the vm in the VirtualBox Manager, like this:

Create Shortcut

What about legacy vm's that you created prior to VirtualBox 4.0?

4.0 is backward compatible so things should just continue to work out of the box, with the vm information held in the old locations. However, some new features, such as file associations, won't work (because the config file is still the old .xml extension not the new .vbox one). 

To migrate to the new 4.0 locations and filetypes you can perform a one-time export/import. You can either do this manually ("File...Export Appliance" and "File...Import Appliance), or you script the process. On Linux/Solaris/Mac it would look like this:

VBoxManage list vms | sed 's/.\*{ \*//;s/}//' | while read UUID; do VBoxManage export $UUID -o /tmp/$UUID.ova; VBoxManage import /tmp/$UUID.ova; done

This may take a bit of time, so I'd run it overnight.

Hope this info is useful to someone.

Cheers,

-FB 

Comments:

Yep, very useful to me. Thanks! Post updating to 4.0, I experience a crash every time that I click on the settings of an existing 3.2 machine. No big deal though, I'll just re-create the machines and move the drives across :-)

-c

Posted by Chris Smart on January 04, 2011 at 09:54 PM GMT #

Would Export/Import make the HardDisk "vmdk" instead of VDI?

Posted by Terry on January 10, 2011 at 01:42 PM GMT #

Terry,
Yes, after import the default virtual disk format is vmdk. That's ok, VirtualBox supports that.
But if you really want a .vdi file you can convert it/them using :
VBoxManage clonehd ...

-FB

Posted by Fat Bloke on January 24, 2011 at 03:49 AM GMT #

Please see http://forums.virtualbox.org/viewtopic.php?f=7&t=39535 shown in ""s below.

What will happen to my guest XP system if I remove VB 3.2.12 and install VB 4.0.4.
I really do not want to lose my guest XP system.

"Retaining guest system on new install.

Postby welshmike » 2. Mar 2011, 12:17
I have VirtualBox 3.2.12 installed on Ubuntu 10.4 and a Windows XP system installed as a guest.
When attempting to install VirtualBox 4.0.4 the following message occurred:
Error: Conflicts with the installed package 'virtualbox-3.2'.
I am considering removing 3.2.12 so that 4.0.4 will install..
I want to retain the Windows XP guest. Will removing 3.2.12 also remove the Windows XP guest?

Please will the team advise?"

Posted by Mike Welsh on March 02, 2011 at 05:28 AM GMT #

Mike,

Removing the VirtualBox package will not remove the vm's.
(Analogous to MS Word and .doc files)

Remember that with 4.x you need to also install the Extension Pack if your vm uses RDP or USB devices.

-FB

Posted by Fat Bloke on March 02, 2011 at 06:00 AM GMT #

Hmm.

I installed VB 4.0.4. successsfuly but when I clicked on http://download.virtualbox.org/virtualbox/4.0.4/Oracle_VM_VirtualBox_Extension_Pack-4.0.4-70112.vbox-extpack my browser Firefox stated that I'd chosen to open the VirtualBox Extension Pack with Oracle VM VirtualBox. On clicking OK VB started. On clicking Start for Windows XP home which was powered off it warned "Implementation of the USB 2 controller not found" ... "install the 'Oracle VM VirtualBox Extension Pack'"

???

Posted by Mike Welsh on March 02, 2011 at 12:21 PM GMT #

Stupid me. I should have saved the Extension Pack and then click on the saved file. I did just that and now it is installed. But my USB device is still not seen by the XP guest.

Posted by Mike Welsh on March 02, 2011 at 03:28 PM GMT #

Mike,

Set up a USB filter, see the manual for details, then restart the vm.

- FB

Posted by Fat Bloke on March 03, 2011 at 01:00 AM GMT #

I had the USB filters set up for my USB devices on VB 3.2. The USB hard drives and USB flash drives never worked. The same filters were inherited by VB 4.0.4. No change. So there has been something fundamentally wrong with my Ubuntu host / XP guest system. I do have guest additions installed. My USB mouse and printers work. Here is a screenshot showing the USB filters:
http://www.hantsnwa.org.uk/Screenshot.png

Posted by Mike Welsh on March 03, 2011 at 05:20 AM GMT #

I'm trying to do a copy/paste from the redhat rhel6 running on top of Windows with virtualbox installed on windows, clipboard is bidirectional, it says I need the addtions (guest), which I need more direction about, I would just instll the Windows portion and I don't see install notes on it at all.. Is there a way to get the software via dvd/cd?

Posted by Deborah Dawicki on March 12, 2011 at 09:21 PM GMT #

Deborah,
You install the guest additions into the virtual machine.
See http://www.virtualbox.org/manual/ch04.html#id404776 for how to do it for Linux guests.

Cheers,
-FB

Posted by Fat Bloke on March 13, 2011 at 07:17 AM GMT #

Hi I had the following issue and tried what it says in the message. However, the problem still remains. Any idea how to resolve it?

“The virtual machine execution may run into an error condition as described below. We suggest that you take an appropriate action to avert the error.
The host I/O cache for at least one controller is disabled and the medium ‘/home/MyUserName/.VirtualBox/HardDisks/Ubuntu_LAMP.vdi’ for this VM is located on an ext4 partition. There is a known Linux kernel bug which can lead to the corruption of the virtual disk image under these conditions.
Either enable the host I/O cache permanently in the VM settings or put the disk image and the snapshot folder onto a different file system.
The host I/O cache will now be enabled for this medium.”

Posted by R4 3DS on March 27, 2011 at 08:30 AM BST #

R4 3DS check out the help available at forums.virtualbox.org

- FB

Posted by Fat Bloke on March 27, 2011 at 09:58 AM BST #

Post a Comment:
Comments are closed for this entry.
About

Fat Bloke

Search

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