[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-discuss] qcow2 performanceimprove
From: |
yang.bin18 |
Subject: |
Re: [Qemu-discuss] qcow2 performanceimprove |
Date: |
Thu, 23 Aug 2018 14:30:41 +0800 (CST) |
> > > > > If there is no backing file or snapshot you still need to fill
> > > > > the cluster with zeroes, and that's going to be slower with
> > > > > larger clusters.
> > > > If not fill zeroes and only write guest data ,what`s wrong could
> > > > happen ?
> > > The following could happen:
> > > 1) Guest reads at offset [0, 4k] -> there's only zeroes
> > > 2) Guest writes at offset [8k, 16k]
> > > 3) Guest reads at offset [0, 4k] -> there's something else now
> > Why could guest read the area at offset [0, 4k] has not be writen
> > yet ?
> Jakob already gave you some answers, but here's a simple one: because
> it might have already been written.
> If the guest wrote zeroes to [0, 1M] you can't generally assume that
> there's an allocated 1MB cluster on the qcow2 file filled with zeroes.
> - QEMU can detect that the guest tried to write zeroes and decide to
> leave the cluster unallocated (see for example the "detect_zeroes"
> option, or the "WRITE SAME" SCSI command).
> - The qcow2 file could have been converted at some point, and
> zero-filled clusters could have been deallocated for efficiency.
> Berto
Thank for every replay,and I understand completely .
Then I look forward to using the “subcluster allocation ”feature as early as
possible.
Yang.bin
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Qemu-discuss] qcow2 performanceimprove ,
yang.bin18 <=