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

[Xen-devel] [PATCH v4 0/5] domain snapshot documents

here is the fourth version about domain snapshot documents, the previous version
is here[1][2][3].

there are lots of potential feature about snapshots. for now, i focus on
providing the api for libvirt libxl driver in order to support the same
functionality compare with libvirt qemu driver.
i plan to work on other "advanced feature" after my first stage patch ack.

there are two types of snapshots supported by libxl: disk snapshot and domain
snapshot and four types of operations: create, delete, list and revert.

Disk snapshot will only be crash-consistent if the domain is running. Disk
snapshots can also be internal (qcow2) or external (snapshot in one file, delta
in another).

Domain snapshots include disk snapshots and domain state, allowing to resume
the domain from the same state when the snapshot was created. This type of
snapshot is also referred to as a domain checkpoint or system checkpoint.

In libvirt, there is a something like resource manager for domain snapshot
managements. So, in libxl, all these information is transfered through
libxl_domain_snapshot struct. xl will manage the snapshot by itself based on
Liu Wei libxl-json apis.

Domain snapshot create means save domain state and do disk snapshots.
At the beginning of domain snapshot create, it will check whether it is

Domain snapshot revert means rollback the current snapshot state.

the domain snapshot information will store in the follow path:
reference patch 0004 for details.

here is some features i do not want to implement in my first version code:

about non-qdisk backend, after some discussion with Jim, it seems that the
snapshot of these device could be done by difference utils through libxl__exec.
for tap/tap2, td-util or vhd-util.
for lvm, snapshot create, delete, revert could be done by lvcreate, lvremove,
lvconvert respectively.

live snapshot.
i do not know how it should work exactly. if we talk about live memory save,
i guess it is simialr to live migration. but i am not sure how to sync with
live memory save and disk transaction.

changes since v3:
split one document into difference document, hope it will be easier to review 

changes since v2:
1), reorgnized the whole docments.
2), do not export the dedicated the disk snapshot commands.
3), others changes according to Ian and Jim's comment.

[1] http://lists.xen.org/archives/html/xen-devel/2014-04/msg00414.html
[2] http://lists.xen.org/archives/html/xen-devel/2014-04/msg02549.html
[3] http://lists.xen.org/archives/html/xen-devel/2014-05/msg01977.html

Bamvor Jian Zhang (5):
  define snapshot API
  add xl snapshot command in xl manpage
  add xl snapshot configuration syntax file
  examples for xl internal snapshot
  examples for xl external snapshot

 docs/man/xl.pod.1                  | 94 ++++++++++++++++++++++++++++++++++++++
 docs/man/xl.snapshot.conf.pod.5    | 58 +++++++++++++++++++++++
 tools/examples/xlsnapshot.external |  7 +++
 tools/examples/xlsnapshot.internal |  6 +++
 tools/libxl/libxl.h                | 37 +++++++++++++++
 5 files changed, 202 insertions(+)
 create mode 100644 docs/man/xl.snapshot.conf.pod.5
 create mode 100644 tools/examples/xlsnapshot.external
 create mode 100644 tools/examples/xlsnapshot.internal


Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.