Hi! I was reading the Wiki about 'Live Disk Backup with Active Blockcommit, https://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit and see that example shown seems to be using two different names for the same file. First showing the current block device in use: $ virsh domblklist vm1 Target Source ------------------------------------------------ vda /export/images/base.qcow2 Then copying the same file for backup: $ cp /export/images/base.img /export/images/copy.img => Is there are reason why the block device first is called 'base.qcow2' and then 'base.img'? I also saw another name that seems to be wrong based on the context. It doesn't have the same implication as my earlier example, as the name of the overlay file is not written in the command itself, but still: ------ $ virsh snapshot-create-as --domain vm1 guest-state1 \ --diskspec vda,file=/export/images/overlay1.qcow2 \ --disk-only --atomic Then: $ virsh domblklist vm1 Target Source ------------------------------------------------ vda /export/images/overlay.qcow2 Now that the backup is finished, perform active blockcommit by live mergning contents of 'overlay1' into base . . . ." ------ => Here it seems like the overlay file first is called ''overlay1.qcow2" and the ' virsh domblklist vm1' command shows that it is actually called: 'overlay.qcow2' And then back to ''overlay1 in the following text: 'mergning contents of 'overlay1' into base' (Where 'mergning' is spelled wrong, but that doesn't affect the logic). => Do I understand all this correctly? I came to this article based on this answer on Serverfault: https://serverfault.com/a/921966 Since I didn't understand the logic of the file changing names, I visited the file linked to in the answer on wiki.libvirt.org and saw that the same was written there. So maybe change these errors in the Wiki if I understand all this correctly? Thanks for input! Best regards, Wolf
Eric Blake
2019-Apr-25 14:26 UTC
Re: [libvirt-users] Live Disk Backup with Active Blockcommit
On 4/25/19 8:59 AM, Wolf wrote:> Hi! > > I was reading the Wiki about 'Live Disk Backup with Active Blockcommit, https://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit > and see that example shown seems to be using two different names for the same file. > > First showing the current block device in use: > $ virsh domblklist vm1 > Target Source > ------------------------------------------------ > vda /export/images/base.qcow2 > > Then copying the same file for backup: > $ cp /export/images/base.img /export/images/copy.img > > => Is there are reason why the block device first is called 'base.qcow2' and then 'base.img'?Nope. Fixed to favor .img throughout, to emphasize that the base image can be ANY format, not just qcow2.> > > I also saw another name that seems to be wrong based on the context. > It doesn't have the same implication as my earlier example, as the name of the overlay file is not written in the command itself, but still: > ------ > $ virsh snapshot-create-as --domain vm1 guest-state1 \ > --diskspec vda,file=/export/images/overlay1.qcow2 \ > --disk-only --atomic > > Then: > $ virsh domblklist vm1 > Target Source > ------------------------------------------------ > vda /export/images/overlay.qcow2 > > Now that the backup is finished, perform active blockcommit by live mergning contents of 'overlay1' into base . . . ." > ------ > > => Here it seems like the overlay file first is called ''overlay1.qcow2" and the ' virsh domblklist vm1' command shows that it is actually called: 'overlay.qcow2' > And then back to ''overlay1 in the following text: 'mergning contents of 'overlay1' into base' > (Where 'mergning' is spelled wrong, but that doesn't affect the logic).Also fixed, here preferring overlay1.qcow2 since it is possible to create a chain of more than one overlay.> > > => Do I understand all this correctly?Yes, thanks for spotting the issues and reporting them. -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3226 Virtualization: qemu.org | libvirt.org