KVM: Create Live backups (snapshot-create-as, blockcommit)

From wikieduonline
Revision as of 13:41, 7 January 2020 by Welcome (talk | contribs) (→‎See also)
Jump to navigation Jump to search

Live-disk-backup-with-active-blockcommit: https://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit


1. Create an external disk snapshot, specify image destination :

virsh snapshot-create-as --domain VM_TO_BACKUP --diskspec vda,file=/export/images/VM_TO_BACKUP_overlay1.qcow2 --disk-only --atomic

--diskspec To indicate external snapshot and location
--disk-only Do not save memory information
--atomic

2. Take a backup of the original disk: cp or rsync

3. virsh blockcommit VM_TO_BACKUP DEVICE --active --verbose --pivot

virsh blockcommit VM_TO_BACKUP vda --active --verbose --pivot


Activities

See also

Advertising: