Description of problem:
Since May 2014, qemu has supported a block device "detect-zeroes"
option, which turns writes of zeroes into either an efficient
zero-write operation or an unmap.
I had previously tried such an approach in qemu (see:
and found that it makes virt-sparsify in normal copying mode
far more space efficient. The reason is that virt-sparsify writes
a big file of just zeroes to an overlay file, and if detect_zeroes
is enabled then the overlay file doesn't actually need to grow much
to handle this (qcow2 can optimize).
So we should enable this feature in virt-sparsify and
the underlying libguestfs API.
Version-Release number of selected component (if applicable):