Trying to convert raw disk to vmdk using PVESM

Coneng

Member
Aug 14, 2015
15
1
23
Trying to use

pvesm export local-zfs:vm-112-disk-0 vmdk /root/112.vmdk

I am getting an error:

400 Parameter verification failed.
format: value 'vmdk' does not have a value in the enumeration 'raw+size, tar+size, qcow2+size, vmdk+size, zfs'
pvesm export <volume> <format> <filename> [OPTIONS]

There is nothing in documentation on how the vmdk+size would look like.
 
There is nothing in documentation on how the vmdk+size would look like.
its literally 'vmdk+size'

so 'pvesm export local-zfs:... vmdk+size /filename'
 
its literally 'vmdk+size'

so 'pvesm export local-zfs:... vmdk+size /filename'

this is what I get
Code:
pvesm export local-zfs:vm-103-disk-0 vmdk+size 103.vmdk
unsupported export stream format for PVE::Storage::ZFSPoolPlugin: vmdk+size
 
Hi!

As an alternative you can try to use the following
Code:
qemu-img convert -p -f raw -O vmdk /dev/zvol/local-zfs/vm-112-disk-0 /root/112.vmdk


Update: One example command that should work (when you have a snapshot "snap1" of the VM) is
Code:
pvesm export zfs:vm-112-disk-0 zfs --snapshot snap1 x

Note: pvesm export is mostly used internally for mirroring. In constrast to the previous qemu-img command changing the filename to something like
Code:
pvesm export zfs:vm-112-disk-0 zfs --snapshot snap1 x.vmdk
does not give you a disk image where you can simply boot from.
 
Last edited: