[sheepdog] [PATCH] dog/cluster: cluster-wide snapshot save or load specified vdi

Liu Yuan namei.unix at gmail.com
Thu May 29 09:34:43 CEST 2014


On Wed, May 28, 2014 at 08:43:02PM +0800, Ruoyu wrote:
> It is useful for users who want to backup or restore only part of
> all vdi from cluster-wide snapshot.
> 
> Usage and example:
> 
> 1. save all vdi:
>    dog cluster snapshot save all /tmp/ss
> 
> 2. save some specified vdi:
>    dog cluster snapshot save test0_1_2 /tmp/ss test0 test1 test2
> 
> 3. load all vdi:
>    dog cluster snapshot load all /tmp/ss
> 
> 4. load some specified vdi:
>    dog cluster snapshot load all /tmp/ss test6 test0 test3

We already give a name test0_1_2 for a snapshot that contain test{0,1,2}, so I
think dog cluster snapshot snap_name would suffice.

I'd suggest following command:

dog cluster snapshot save snap_name /path # save all the vdi
dog cluster snapshot save snap_name /path vdi0:snap_name,vdi1:snap_name,... # partially save
dog cluster snapshot load snap_name /path # load the specified snapshot, be it all or partial
dog cluster snapshot list /path # list all the snapshot as before
dog cluster snapshot show snap_name /path # show the saved vdis as in format

name  snapid  snapname
A       1       A_snap1
A       2       A_snap2
B       1       B_snap
C       1       C_snap

Thanks
Yuan



More information about the sheepdog mailing list