Stefan Hajnoczi

Results 38 comments of Stefan Hajnoczi

`--target-is-zero` was introduced in QEMU 5.0.0 in April 2020. You can get an idea of which Linux distro releases include that QEMU version here: https://repology.org/project/qemu/versions It is available starting from...

> I am wondering how a certain test we have isn't catching this This du(1) command-line probably isn't working as expected on a block device: https://github.com/kubevirt/containerized-data-importer/blob/main/tests/framework/pvc.go#L552

There is no generic way in Linux to query a block device to find out how many blocks are allocated, so SizeOnDisk will not have a useful value.

Maybe this trick will work: create a sparse file using truncate(1) and then create a corresponding loopback block device using losetup(8). The test would be able to look at the...

> Can't we just use dd and copy the content into a scratch filesystem volume? If I understand correctly, the test is attempting to verify that the block device was...

Ceph might be doing zero detection or deduplication? Even if this is the case, you should be able to see the issue by running the same qemu-img command-line as CDI...

The loop device results are surprising to me. I expected the number of allocated blocks to be less for `--target-is-zero`. Not sure why this happens.

@akalenyu and I came across an issue specific to preserving sparseness on LVM thin LVs. Using `--target-is-zero` avoids the issue. I'm capturing the details here in case they are needed...