diff options
author | edison <edison@cloud.com> | 2010-09-21 19:58:41 -0700 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2010-10-22 14:49:35 +0200 |
commit | 51ef67270b1d10e1fcf3de7368dccad1ba0bf9d1 (patch) | |
tree | a06b3ce03bae7ed77a1e1e9bebc6ead157c7a4e5 /block/qcow2.h | |
parent | a58b8d5401b6064d52113f243456115d046bdd12 (diff) |
Copy snapshots out of QCOW2 disk
In order to backup snapshots, created from QCOW2 iamge, we want to copy snapshots out of QCOW2 disk to a seperate storage.
The following patch adds a new option in "qemu-img": qemu-img convert -f qcow2 -O qcow2 -s snapshot_name src_img bck_img.
Right now, it only supports to copy the full snapshot, delta snapshot is on the way.
Changes from V1: all the comments from Kevin are addressed:
Add read-only checking
Fix coding style
Change the name from bdrv_snapshot_load to bdrv_snapshot_load_tmp
Signed-off-by: Disheng Su <edison@cloud.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/qcow2.h')
-rw-r--r-- | block/qcow2.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/block/qcow2.h b/block/qcow2.h index add710ba76..2d22e5ec47 100644 --- a/block/qcow2.h +++ b/block/qcow2.h @@ -211,6 +211,7 @@ int qcow2_snapshot_create(BlockDriverState *bs, QEMUSnapshotInfo *sn_info); int qcow2_snapshot_goto(BlockDriverState *bs, const char *snapshot_id); int qcow2_snapshot_delete(BlockDriverState *bs, const char *snapshot_id); int qcow2_snapshot_list(BlockDriverState *bs, QEMUSnapshotInfo **psn_tab); +int qcow2_snapshot_load_tmp(BlockDriverState *bs, const char *snapshot_name); void qcow2_free_snapshots(BlockDriverState *bs); int qcow2_read_snapshots(BlockDriverState *bs); |