I would like to turn the disk image from a cloud image (former UEC image) into a bootable VirtualBox (for Vagrant). I can run the image in kvm (using https://help.ubuntu.com/community/UEC/Images as a starter), but how can I turn the .img disk file into a bootable VirtualBox disk? I would rather not use the floppy as boot.
The solution is indeed to make the image itself bootable. After days of searching the interwebs I found that the solution is to use the package extlinux, which is a derivative of syslinux — a solution for making FAT disks bootable. extlinux works on e2fs and derivatives, this works perfectly on any old ext2 system.
This will make the image bootable, and disable built-in cloud initialization techniques and so on.
Notes: I haven't worked out how to specify an APPEND which allows it to use the "root=LABEL=cloudimage-rootfs".
The resulting image can then boot using qemu, kvm or vmware, without additional floppies, kernels, or anything. And from what I understand, apt-get upgrading the kernel will make that kernel active the next boot.
edit: I forgot to mention the obvious that you need to perform this loop-back mounting on the raw disk image, and then convert the resulting file to a VDI using
Perhaps this is useful? http://en.wikibooks.org/wiki/QEMU/Images#Exchanging_images_with_VirtualBox