I have received a .img file of a server which is a Virtual Machine running in a KVM environment. The Virtual Machine was installed with Ubuntu.

I would now like to take this .img file and "emulate" the server within VirtualBox. So I have converted the .img file to a .vdi file using qemu-img from raw to vdi, however the VirtualBox instance starts up and simply states:

FATAL: No bootable medium found! System halted.

I do not know if I would have to install KVM in VirtualBox and then configure it to run the VM in my .img file, or if I would be able to convert the image from KVM to VDI and then just run the server in VirtualBox directly.

What I have tried already is using qemu to convert the .img raw file to a .vdi, but that produced the above errors.

I have also read the answer on this Server Fault question, but this question is slightly different, as it is talking about moving a Windows VM from KVM to VirtualBox.

I have also tried converting from qcow2 to vdi using the qemu-img linux package, however I continually get the following error messages:

#> qemu-img convert -f qcow2 original.img -O vdi converted.vdi
qemu-img: Could not open './duketest.img': Invalid argument
qemu-img: Could not open './duketest.img'

I have also tried converting using the VBoxManage command as shown on this page:


This also provides the error message I mentioned at first:

FATAL: No bootable medium found! System halted.

Thanks in advance!

  • @stbonearth don't worry, this is a perfectly appropriate question as currently worded. Hopefully somebody will be able to provide an answer for you soon.
    – nhinkle
    Sep 12 '14 at 18:03
  • I don't think KVM will install in virtualbox since KVM needs VT-X support to run. I do have copies of both so I'll see if I can test.
    – Journeyman Geek
    Sep 12 '14 at 23:28
  • Just so I can replicate the environment in case my answer is missing something - what specific distro does this server run?
    – Journeyman Geek
    Sep 13 '14 at 2:29

There's a few small issues with your conversion stanza.

qemu-img convert -f qcow2 original.img -O vdi converted.vdi tells you to explicitly convert a qcow2 file to a VDI, and you have an raw image file. You essentially told your computer to translate a french text, using a spanish translator, into english.

You are better off with qemu-img convert -O vdi original.img original.vdi - letting qemu decide what's the format of the input implicitly. If you must, I believe the right input format for a img is raw, not qcow.

I've tested using the command I used in conversion from from qcow2 to VDI and and from a raw file to a VDI it works. (Interestingly qcow2 to raw to VDI dosen't.)

Just to confirm what I did

  1. Create a VM with libvirt-manager with a qcow or img disk image
  2. Install Ubuntu Minimal
  3. Check if the system boots
  4. Use qemu-image with mu-img convert -O vdi original.ext original.vdi for both files
  5. Move the file over to a windows/virtualbox system
  6. Check to see if it boots.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.