[SOLVED] Compress template VMs?

Terrum

Renowned Member
Mar 7, 2014
36
4
73
I am using raw for my VMs, but for templates I am trying to figure out what is the best way to get the most compressed filesize so that I can save more space for active VMs rather than have space used by templates. I am using '.vmdk' for templates currently but sometimes these still take full size as '.raw' (e.g: if I have 50GB raw file, sometimes cloning to vmdk will show 50GB vmdk file, but it only seems to happen with some VMs? Maybe the way it stores the data, I don't know).

So my question is, what is the best way to get the highest compression for my templates? Which format should I use? Many thanks
 
Is there a specific reason why you use .vmdk? With Proxmox VE I'd always choose qcow2 or raw and not .vmdk

QEMU also supports various other image file formats for compatibility with older QEMU versions or other hypervisors, including VMDK, VDI, VHD (vpc), VHDX, qcow1 and QED. For a full list of supported formats see "qemu-img --help". For a more detailed description of these formats, see the QEMU Emulation User Documentation.

The main purpose of the block drivers for these formats is image conversion. For running VMs, it is recommended to convert the disk images to either raw or qcow2 in order to achieve good performance. (Source)
 
Is there a specific reason why you use .vmdk? With Proxmox VE I'd always choose qcow2 or raw and not .vmdk
Merely because VMDK offers better compression, which is better suited when using inactive VMs as templates. I assume from your quote however that there is no better compression method, however please correct me if I'm wrong.