[libvirt] QEMU/KVM snapshots, and rudimentary API extension

Philip Jameson pjameson at pjameson.us
Fri Jan 1 00:42:30 UTC 2010

I was starting to use libvirt on a project, and realized that there was nothing in the API for snapshots. As I need to be able to take snapshots without taking down the machine (that and KVM's restore function didn't seem to be working terribly well), I added a few functions so that I could take snapshots, and I also added a screenshot function so I could give users a view of their snapshots in my application. At this point, as I only really use KVM/QEMU, that is the only hypervisor I implemented it for, and I'm sure there will be some problems with my structure in the other drivers. However, I figured I should at least submit the patch, even if it turns out to be of no use to anyone :)

At this point for the QEMU driver, it only does snapshots for qcow2 drives, and will report an error if qemu says that no valid drives were found, or if for restoring/deleting the specified snapshot wasn't found.

Philip Jameson

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: snapshot-diff.txt
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20091231/ff15e11c/attachment-0001.txt>

More information about the libvir-list mailing list