Use Openstack img in Virtualbox

I needed to add some packages to our base Openstack image install recently. The easiest way to do this is to export the img file from Openstack and run it in Virtualbox.

Everything I could find told me that I need to convert the img to a VDI file wit the following command:

VBoxManage convertfromraw --format VDI centos6.7-image.img centos6.7-image.vdi

However, this only resulted in an error.

FATAL: No bootable medium found! System halted.

It turns out that VBoxManage can’t convert things correctly. Instead, I needed to install qemu and use that to conver the disk image

qemu-img convert -O vdi centos6.7-image.img centos6.7-image.vdi

Once this completed, I could create a machine and attach the vdi file as the disk and everything booted fine

Michael is a polyglot software engineer, committed to reducing complexity in systems and making them more predictable. Working with a variety of languages and tools, he shares his technical expertise to audiences all around the world at user groups and conferences. You can follow @mheap on Twitter

Thoughts on this post

Leave a comment?

Leave a Reply