On Tue 14 Apr 2020 06:19:18 PM CEST, Vladimir Sementsov-Ogievskiy <vsement...@virtuozzo.com> wrote: >>> It still may cache information about zeroed subclusters: gives more >>> detailed block-status. But we should mention somehow external >>> files. Hm. not only for raw external files, but it is documented that >>> cluster can't be unallocated when an external data file is used. >> >> What do you mean by "cluster can't be unallocated" ? > > I mean this sentence from qcow2.txt: > > "The offset may only be 0 with > bit 63 set (indicating a host cluster offset of 0) when > an > external data file is used." > > In other words, cluster can't be unallocated with data file in use.
I still don't follow... clusters can be unallocated, and when you create a new image they are indeed unallocated. Bit 63 (QCOW_OFLAG_COPIED) is what indicates if a cluster is allocated or not, and you can unmap an allocated cluster with 'write -z -u'. Berto