If you so happen to have the VMware OVF version of CloudFORMs CFME, and you want to convert to run on KVM, this is how.

1. If the OVF is zipped, Unzip the appliance image:

$ unzip

2. Convert each of the 5 disks from VMDK format to RAW:
$ for i in `seq 1 5`; do qemu-img convert -p evm-v5.1.0.4-r/ovf-disk$i.vmdk disk$i.img; done

3. Remove unneeded files
$ rm -rf evm-v5.1.0.4-r/

4. Move your disk[1-5].img into place in /var/lib/libvirt/images, with the correct ownership.

5. Use virt-manager to create a VM such that disk1.img is an IDE disk, and disk[2-5].img are SCSI disks.  If it helps, here’s the libvirt XML for my VM:

$ virsh dumpxml cloudforms2

<domain type='kvm' id='7'>
<memory unit='KiB'>4194304</memory>
<currentMemory unit='KiB'>4194304</currentMemory>
<vcpu placement='static'>4</vcpu>
<type arch='x86_64' machine='pc-1.2'>hvm</type>
<boot dev='hd'/>
<clock offset='utc'/>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/disk1.img'/>
<target dev='hda' bus='ide'/>
<alias name='ide0-0-0'/>
<address type='drive' controller='0' bus='0' target='0' unit='0'/>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/disk2.img'/>
<target dev='sda' bus='scsi'/>
<alias name='scsi0-0-0'/>
<address type='drive' controller='0' bus='0' target='0' unit='0'/>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/disk3.img'/>
<target dev='sdb' bus='scsi'/>
<alias name='scsi0-0-1'/>
<address type='drive' controller='0' bus='0' target='0' unit='1'/>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/disk4.img'/>
<target dev='sdc' bus='scsi'/>
<alias name='scsi0-0-2'/>
<address type='drive' controller='0' bus='0' target='0' unit='2'/>
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/disk5.img'/>
<target dev='sdd' bus='scsi'/>
<alias name='scsi0-0-3'/>
<address type='drive' controller='0' bus='0' target='0' unit='3'/>
<controller type='usb' index='0'>
<alias name='usb0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
<controller type='ide' index='0'>
<alias name='ide0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
<controller type='scsi' index='0'>
<alias name='scsi0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
<interface type='network'>
<mac address='52:54:00:07:10:58'/>
<source network='default'/>
<target dev='vnet0'/>
<model type='virtio'/>
<alias name='net0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
<input type='mouse' bus='ps2'/>
<graphics type='vnc' port='5900' autoport='yes' listen=''>
<listen type='address' address=''/>
<model type='vmvga' vram='9216' heads='1'/>
<alias name='video0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
<memballoon model='virtio'>
<alias name='balloon0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
<seclabel type='none'/>


Jim Minter – Thanks for the instructions on how to achieve this.

  1. After you finish converting the disk1 …. disk5 and put them in a folder such as /home/jzhou/VMs/EVM05104, you can create the VM using “virt-install” as below.

    virt-install –name=EVM
    –disk path=/home/jzhou/VMs/EVM-5104/disk0,format=qcow2,bus=ide
    –disk path=/home/jzhou/VMs/EVM-5104/disk1,format=qcow2,bus=virtio
    –disk path=/home/jzhou/VMs/EVM-5104/disk2,format=qcow2,bus=virtio
    –disk path=/home/jzhou/VMs/EVM-5104/disk3,format=qcow2,bus=virtio
    –disk path=/home/jzhou/VMs/EVM-5104/disk4,format=qcow2,bus=virtio


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s