On Wed, May 22, 2013 at 11:46:15PM +0200, Paolo Bonzini wrote: > Il 22/05/2013 22:47, Richard W.M. Jones ha scritto: > >> > > >> > I meant if there was interest in reading from a disk that isn't fully > >> > synchronized > >> > (yet) to the original disk (it might have old blocks). Or would you only > >> > want to > >> > connect once a (complete) snapshot is available (synchronized completely > >> > to > >> > some point-in. > > IIUC a disk which wasn't fully synchronized wouldn't necessarily be > > interpretable by libguestfs, so I guess we would need the complete > > snapshot. > > In the case of point-in-time backups (Stefan's block-backup) the plan is > to have the snapshot complete from the beginning.
The way it will work is that the drive-backup target is a qcow2 image with the guest's disk as its backing file. When the guest writes to the disk, drive-backup copies the original data to the qcow2 image. The qcow2 image is exported over NBD so a client can connect to access the read-only point-in-time snapshot. It is not necessary to populate the qcow2 file since it uses the guest disk as its backing file - all reads to unpopulated clusters go to the backing file. Stefan