Page 1 of 1

Sharing violation importing an OVF

Posted: 7. May 2014, 20:19
by Tronmech
I am trying to import a VMWare virtual machine that I converted to an OVF file using VMWare's OVFtool.

It worked on my first VM, but for some reason not this one. When I import the file, I get this:

Failed to import appliance D:\vmstorage\HoneywellTest2\Honeywelltest2.ovf.

Could not open the medium storage unit 'D:\vmstorage\vbox\vm/temp_test2-disk1.vmdk'.

VD: error VERR_SHARING_VIOLATION opening image file 'D:\vmstorage\vbox\vm/temp_test2-disk1.vmdk' (VERR_SHARING_VIOLATION).

Result Code: VBOX_E_FILE_ERROR (0x80BB0004)
Component: Appliance
Interface: IAppliance {3059cf9e-25c7-4f0b-9fa5-3c42e441670b}

I then wind up with a 11GB disk file and nothing else. The disk file is opened/locked by vboxsvc.exe (the VirtualBox backend, I think), so it's very weird.

I converted it using the command ovftool --compress=3 --name=test2 test.vmx test.ovf

I'm trying it again with just the to and from files. Should I just KISS and not fiddle with compression options?

Are there any other options I should avoid? I have a lot of VM's to convert/import... I'm looking at the cli for importing (vboxmanage import) and is there a list of the command line options other than to watch vboxmanage -import --dry_run?

Re: Sharing violation importing an OVF

Posted: 8. May 2014, 16:35
by Tronmech
Well, I got past the "sharing violation" error using an uncompressed disk image...

Now, on the other hand, I get a fun little error because it wants to attach my Virtual Hard disk to a SAS driver:
Failed to import appliance C:\Users\bcowan.DEV\test2.ovf.

Could not open the medium storage unit 'C:\Users\test.DEV\test2-disk1.vmdk'.

VMDK: incorrectly quoted value in descriptor in 'C:\Users\test.DEV\test2-disk1.vmdk' (VERR_VD_VMDK_INVALID_HEADER).

VD: error VERR_VD_VMDK_INVALID_HEADER opening image file 'C:\Users\bcowan.DEV\honeywelltest2-disk1.vmdk' (VERR_VD_VMDK_INVALID_HEADER).

Result Code: VBOX_E_FILE_ERROR (0x80BB0004)
Component: Appliance
Interface: IAppliance {3059cf9e-25c7-4f0b-9fa5-3c42e441670b}

Since I happen to have the original vmdk fileset still, I'm trying that as the hard drive for the system. And that works. Perhaps I'm barking up the wrong tree. Time to import it using vmware since this came from vmware.

Re: Sharing violation importing an OVF

Posted: 8. May 2014, 21:43
by Tronmech
* Original VMDK disk booted within Virtualbox, but screwed up trying to log into the Windows domain it was a member of ("Domain trust failed" message on login).
* Booted the same disk back in VMWare workstation, and windows now said it wasn't genuine, though the domain login at least worked.
* Tried to load the ovf file in VMWare workstation, just for the sake of completeness at this point. Workstation said that the SHA5 didn't match.

So, Virtualbox's new error was likely correct, VMWare's ovftool generated a bad archive.