Bug 998279 - [RFE] Import VirtualBox .VDI disk image file in Ovirt
[RFE] Import VirtualBox .VDI disk image file in Ovirt
Status: NEW
Product: ovirt-engine
Classification: oVirt
Component: RFEs (Show other bugs)
---
Unspecified Unspecified
unspecified Severity low (vote)
: ---
: ---
Assigned To: Nobody's working on this, feel free to take it
Raz Tamir
: FutureFeature
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-08-18 17:07 EDT by Moez Roy
Modified: 2017-10-25 06:53 EDT (History)
13 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: Storage
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
ylavi: ovirt‑future?
ylavi: planning_ack?
ylavi: devel_ack?
ylavi: testing_ack?


Attachments (Terms of Use)

  None (edit)
Description Moez Roy 2013-08-18 17:07:51 EDT
Description of problem:

It is simple to attach disk image files such as:  Microsoft Virtual PC .VHD, VMware Workstation .VMDK, and VirtualBox .VDI files inside VirtualBox.

------------------------------------------
In VirtualBox click New then:
1. Choose Name and OS
2. RAM size
3. Use an existing virtual hard drive file
-------------------------------------------

How do I open VirtualBox .VDI disk image file in oVirt?
Comment 1 Itamar Heim 2013-08-20 05:44:57 EDT
rich - iiuc, these should first be converted by v2v?
Comment 2 Richard W.M. Jones 2013-08-20 05:52:31 EDT
It depends if the disk image files contain operating systems or
just data disks.

If operating systems, converting them in virt-v2v is essential.

For data disks, perhaps oVirt could provide an easier way to just
attach them to existing guests (performance wouldn't be great however).
For now you can run the following:
  qemu-img convert -O qcow2 data-disk.vdi data-disk.qcow2
Make sure you've got a very recent version of qemu-img, because older
versions are known to silently corrupt certain types of disk.
Comment 3 Moez Roy 2013-08-20 20:19:48 EDT
(In reply to Richard W.M. Jones from comment #2)
> It depends if the disk image files contain operating systems or
> just data disks.
> 
> If operating systems, converting them in virt-v2v is essential.
> 
> For data disks, perhaps oVirt could provide an easier way to just
> attach them to existing guests (performance wouldn't be great however).
> For now you can run the following:
>   qemu-img convert -O qcow2 data-disk.vdi data-disk.qcow2
> Make sure you've got a very recent version of qemu-img, because older
> versions are known to silently corrupt certain types of disk.

The default behaviour of VirtualBox is to use only 1 disk image for the OS (as well as the data).

http://libvirt.org/drvvbox.html says that VirtualBox is supported? 

So can open I the OS stored inside a .VDI disk image file using oVirt? 
(i.e. without converting using virt-v2v or qemu-img convert)
Comment 4 Richard W.M. Jones 2013-08-21 05:17:43 EDT
(In reply to quickbooks.office from comment #3)
> The default behaviour of VirtualBox is to use only 1 disk image for the OS
> (as well as the data).

You need to convert it using virt-v2v, *if* that is possible.  When
I originally read this bug report I thought it was about VMware.
I don't know if anyone has tried converting VirtualBox images or
if virt-v2v supports them.

Matt ^^ have you ever thought about converting VirtualBox images
with virt-v2v or guestconv?

> http://libvirt.org/drvvbox.html says that VirtualBox is supported? 

This link is for libvirt controlling a virtualbox hypervisor.  It's
got nothing to do with oVirt support for vdi disk images.
Comment 5 Richard W.M. Jones 2013-08-21 05:21:17 EDT
(In reply to Richard W.M. Jones from comment #4)
> (In reply to quickbooks.office from comment #3)
> > The default behaviour of VirtualBox is to use only 1 disk image for the OS
> > (as well as the data).
> 
> You need to convert it using virt-v2v, *if* that is possible.  When
> I originally read this bug report I thought it was about VMware.
> I don't know if anyone has tried converting VirtualBox images or
> if virt-v2v supports them.
> 
> Matt ^^ have you ever thought about converting VirtualBox images
> with virt-v2v or guestconv?

The answer to this is that virt-v2v can remove virtualbox
agents, but it's unlikely that anyone has tested whether
it really works with virtualbox images end to end.
Comment 6 Moez Roy 2013-12-07 00:08:35 EST

(In reply to Richard W.M. Jones from comment #5)
> (In reply to Richard W.M. Jones from comment #4)
> > (In reply to quickbooks.office from comment #3)
> > > The default behaviour of VirtualBox is to use only 1 disk image for the OS
> > > (as well as the data).
> > 
> > You need to convert it using virt-v2v, *if* that is possible.  When
> > I originally read this bug report I thought it was about VMware.
> > I don't know if anyone has tried converting VirtualBox images or
> > if virt-v2v supports them.
> > 
> > Matt ^^ have you ever thought about converting VirtualBox images
> > with virt-v2v or guestconv?
> 
> The answer to this is that virt-v2v can remove virtualbox
> agents, but it's unlikely that anyone has tested whether
> it really works with virtualbox images end to end.

Why would you need to run virt-v2v when you can just uninstall the VirtualBox Guest Additions after you load up the OS?

For example when I wanted to a virtualize a physical PC with Windows on it, I ran this tool: Disk2vhd v1.64 http://technet.microsoft.com/en-ca/sysinternals/ee656415.aspx

Then I opened the resulting VHD image file inside VirtualBox and uninstalled the graphics driver (Intel/Nvidia) using Add/Remove programs.

After that I installed VirtualBox Guest Additions to get 3D acceleration / full screen resize etc.
Comment 7 Moez Roy 2013-12-11 10:29:19 EST
(In reply to Richard W.M. Jones from comment #2)
> For data disks, perhaps oVirt could provide an easier way to just
> attach them to existing guests (performance wouldn't be great however).

Well, how do you just attach a disk image (like .vdi, .vmdk, or .vhd) to an existing right now? Screenshots appreciated :)
Comment 8 Itamar Heim 2014-01-12 03:43:18 EST
setting target release to current version for consideration and review. please do not push non-RFE bugs to an undefined target release to make sure bugs are reviewed for relevancy, fix, closure, etc.
Comment 9 Moez Roy 2014-01-21 18:06:33 EST
I am able to open ViurtualBox .VDI disk image (which contains the OS) via virt-manager.

See Bug 952908:

(Martin Kletzander from comment #6)
> The problem is that virt-manager doesn't detect the VDI format properly. 
> This can be seen from the log output where the machine is being generated
> with:
> 
> <driver name='qemu' type='raw'/>
> 
> You can workaround this with clicking "Customize configuration before
> install" and select "VDI" as a format of the disk image.  The support for
> probing VDI files is not yet implemented, though.
Comment 10 Michal Skrivanek 2014-02-14 09:25:31 EST
IIUC this is about a non-system disk, just to be able to add/discover such a disk to a VM. I think you'd need to import it into the storage domain first. Moving to "storage" to consider

integration with v2v for whole VM import is a different matter
Comment 11 Allon Mureinik 2015-01-27 17:09:34 EST
(In reply to Michal Skrivanek from comment #10)
> IIUC this is about a non-system disk, just to be able to add/discover such a
> disk to a VM. I think you'd need to import it into the storage domain first.
> Moving to "storage" to consider
> 
> integration with v2v for whole VM import is a different matter

Aren't we already integrating with v2v for 3.6.0?
Comment 12 Michal Skrivanek 2015-01-28 03:20:49 EST
my understanding is this is not about virt-v2v, as per comment #9 we should be able to use the .vdi directly.

Note You need to log in before you can comment on or make changes to this bug.