I am trying to migrate a VM from KVM to Virtualbox (win7 64bit). I was able to convert the disk image using these commands:
VBoxManage convertfromraw -format VDI XX.img XX.vdi
qemu-img convert -f qcow2 XX.img -O vdi XX.vdi
I also tried to convert first to raw then to vdi. Still when i mount the new disk to virtual box either under IDE or SATA controller. The system does not boot at all. Gives (windows loading files..) then reboots.
Any advice is much appreciated, I might be missing a detail.
Best Answer
When you move the disk image, the installed OS is not aware of that, and it tries to boot with the drivers for the controllers of the previously used virtualization platform. Windows, when it cannot find the driver for the currently installed disk controller, BSOD's and reboots.
This is pretty much the same as moving a windows hard drive between different hardware platforms.
There can be two solutions - either use a v2v converter that can convert from KVM to VBox (I don't know of any, but if you do, please share), or inject the drivers into the VM's image before you start it in a new environment. The easiest way to do that would be to do the follwoing:
mergeide.reg
(you can find it on MS website and pretty much all over the internets)qemu-img
to a vbox formatsmall disk for them to take effect)