Best wishes for 2021! :)
So I've been reading and playing around with live snapshots and still haven't figured out how to use an external memory snapshot. My goal is to take a disk+memory snapshot of a running VM and, if possible, save it in external files.
As far as I understand, I can run:
$ virsh snapshot-create $VM
... and that'll take an *internal* live snapshot of a given VM, consisting of its disks and memory state, which will be stored in the qcow2 disk(s) of the VM. In particular, the memory state will be stored in the first disk of the VM. I can then use the full range of snapshot commands available: revert, list, current, delete.
Now, an external snapshot can be taken with:
$ virsh snapshot-create-as --domain $VM mysnapshot --diskspec vda,file=/home/riccardo/disk_mysnapshot.qcow2,snapshot=external --memspec file=/home/riccardo/mem_mysnapshot.qcow2,snapshot=external
... with as many "--diskspec" as there are disks in the VM.
I've read the virsh manual and the libvirt API documentation, but it's not clear to me what exactly I can do then with an external snapshot, in particular with the file containing the memory state. In articles from 7-8 years ago people state that external memory snapshots cannot be reverted... is it still the case today? If so, what's a typical usage for such files? If not with libvirt, is it possible to revert to an external memory + disk state in other ways, for instance through qemu commands?