As I have EC2 Metadata working on my vSphere (6.5) cluster, I'd like to import Cloud images to it, such as Ubuntu or CoreOS.
But they come in .qcow2 or .img (for CoreOS, which I believe is also qcow2) for OpenStack, usually.
I tried to convert them but I can't figure any way to use them in virtual machine in vSphere.
qemu-img -f qcow2 -O vmdk in.qcow2 out.vmdk
vmkfstools -i in.vmdk -d thin out.vmdk
Doesn't work. I also tried adding "-o compat6" and "-o adapter_type=lsilogic,subformat=streamOptimized,compat6", but it doesn't work. If I put "-f raw" (or remove "-f" option) it doesn't work any better...
The closest thing I got to work was trying the raw image of CentOS Cloud Image, converting it using instructions above (with "raw" instead of "qcow2"), it then boots but Grub crashes with some XFS errors above. Anyway, I'd prefer to boot qcow2 images than raw, as they're more common with CloudInit.
Is it possible to convert those qcow2 images to working and bootable vmdk ?
Thanks