VirtualBox

Opened 5 years ago

Last modified 5 years ago

#18709 new defect

Problems importing .ova appliances on 6.0 versions

Reported by: MBE76 Owned by:
Component: OVF Version: VirtualBox 6.0.8
Keywords: ova appliance import Cc:
Guest type: Windows Host type: other

Description

I've been experiencing an issue when importing .ova appliances on all 6.0 versions, included the latest ( 6.0.8 ).

Just after importing it, it works fine. But if I log on to Windows with another user and try to add (via "Machine -> Add" in VirtualBox Manager) the already imported virtual machine, I get an error message with result code "VBOX_E_OBJECT_NOT_FOUND (0x80BB0001)", and the operation fails. In the details, it says "Could not find an open hard disk with UUID ...". Also, when I'm logged with the same Windows user that imported the .ova appliance, if I remove the virtual machine (without deleting its files) and then try to add it again ("Machine -> Add"), I get the same error. These problems never happened to me on 5.2 versions.

I've realized that, just after importing the .ova appliance, the .vbox file lacks section <MediaRegistry>, and also subsection <HardDisks>. Despite this, for the same Windows user that has imported the appliance, for some reason it works at first.

A workaround that I've found is, just after importing the .ova appliance, to remove hard disks attachments and then add them again. Doing this, section <MediaRegistry> (and subsection <HardDisks>) gets written in .vbox file. After this operation, other Windows users can add the virtual machine.

Thank you.

Change History (2)

comment:1 by MBE76, 5 years ago

It has been fixed in the latest test build: version 6.0.9 revision 131396.

in reply to:  description comment:2 by Socratis, 5 years ago

Replying to MBE76:

Excellent detective work there MBE76! I found the same bug by accident, during the investigation of ticket #17908, but it wasn't involving a VM import. Still the same logic applies.

I've realized that, just after importing the .ova appliance, the .vbox file lacks section <MediaRegistry>, and also subsection <HardDisks>.

Just to give you a really worse scenario, it also contains the encryption keys if you have encrypted the VM. A user in the forums got bitten by it. Thankfully there was a backup.

Despite this, for the same Windows user that has imported the appliance, for some reason it works at first.

And here's the explanation in case you're interested...

There is a "global" <MediaRegistry> section in "VirtualBox.xml" and when first imported, a VM's media ends up there. The <MediaRegistry> sections of "VirtualBox.xml" and all the VMs are combined to create a global media database. That's why it works.

Now, move/copy a VM with its "<VM>.vbox" and corresponding files, and you lose all your media because the specific <MediaRegistry> section is left behind in "VirtualBox.xml", which is a per user file. I managed to lose 11 VM definitions this way! :o

I was working with the devs over IRC to figure out exactly what was going on and why, and they were able to successfully reproduce it. Hopefully now it's fixed as you confirmed, thank you for that!

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use