Backup of KVM guests when using qcow2 disk files
You'll want to coordinate that within the guest .. ideally you:
- Cause any RDBMS running in the guest to flush its cache
- Tell Linux to sync disks (sysrq S or just type 'sync')
Then just make a qcow2 snapshot of the guest. You then have a read-only immutable copy of the guest FS as it was when you took the snapshot.
This page offers a lot more information than you probably wanted to know on how snapshots (and qcow2 itself) works. See also the accepted answer to this question.
I was looking for similar solution, now I'm using software RAID+LVM2 volume for libvirt storage, I've taken a snapshot and few times (about 8-10) I had to revert to backup and it worked, even if Win guest said: unclean shutdown. I'm not using hardware RAID anyway, software is enough but prorably SCSI/SAS + HW RAID + battery backup is the best solution for LVM2 snapthots (due to double write to different places on hard disks when snapshot is taken). I always use full-filled RAW volume files or even direct attached drive/partition, recenty I've enabled write cache for VMs drives which increased write speed A LOT! Now I'm considering QCOW2's built-in snapshots to turn off LVM2, becouse it's very slow when compared to RAW partition, like EXT4.