[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCHv3 06/43] snapshot: track current snapshot across restarts

On 08/24/2011 10:26 AM, Daniel P. Berrange wrote:
On Wed, Aug 24, 2011 at 09:22:23AM -0600, Eric Blake wrote:
Audit all changes to the qemu vm->current_snapshot, and make them
update the saved xml file for both the previous and the new
snapshot, so that there is always at most one snapshot with
<active>1</active>  in the xml, and that snapshot is used as the
current snapshot even across libvirtd restarts.

* src/conf/domain_conf.h (_virDomainSnapshotDef): Alter member
type and name.
* src/conf/domain_conf.c (virDomainSnapshotDefParseString)
(virDomainSnapshotDefFormat): Update clients.
* docs/schemas/domainsnapshot.rng: Tighten rng.
* src/qemu/qemu_driver.c (qemuDomainSnapshotLoad): Reload current
(qemuDomainSnapshotCreateXML, qemuDomainRevertToSnapshot)
(qemuDomainSnapshotDiscard): Track current snapshot.
  docs/schemas/domainsnapshot.rng |    5 ++-
  src/conf/domain_conf.c          |    6 ++-
  src/conf/domain_conf.h          |    4 +-
  src/qemu/qemu_driver.c          |   81 +++++++++++++++++++++++++++++----------
  4 files changed, 72 insertions(+), 24 deletions(-)


5 and 6 are now pushed. There is still a bug in tracking the current snapshot across virDomainSnapshotDelete(, VIR_DOMAIN_SNAPSHOT_DELETE_CHILDREN), fixed in patch 8.5/43, but that one still needs a review before I can push it.

Eric Blake   eblake redhat com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]