Categories
Linux

KVM – Live backups with qcow2

List the current block device in use:
# virsh domblklist <VMNAME>
Target Source
------------------------------------------------
vda /path/to/<VMNAME>.qcow2

Create an external disk snapshot:
# virsh snapshot-create-as --domain <VMNAME> <VMNAME>-snap1 --disk-only --atomic --quiesce

Now that the guest is using the external snapshot disk we can take a backup of the original disk in background using your favorite tool.

When the backup is finished, perform active blockcommit by live merging contents of <VMNAME>-snap1 into base:
# virsh blockcommit <VMNAME> vda --active --verbose --pivot
Block Commit: [100 %]
Successfully pivoted

List the current block device in use, again. It can be noticed, once the blockcommit operation is completed, the live QEMU is pivoted to the base image again:
# virsh domblklist <WMNAME>
Target Source
------------------------------------------------
vda /path/to/<VMNAME>.qcow2

Finaly, if we want, we can remove the external snapshot to not to leave it there:

# virsh snapshot-delete <VMNAME> <VMNAME>-snap1 --metadata
Domain snapshot <VMNAME>-snap1 deleted

Then remove the <VMNAME>-snap1.qcow2 file created above.

Categories
Bikes

Harley Davidson Sportster Manuals

Owner manual and Service manual for the Harley Davidson Sportster.

 

Harley Davidson Sportster 1986-2003 Service Manual

Harley-Davidson-1970-03 XLH Owners Manual