Re: Ceph pool snapshots

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

 



On Sun, Aug 21, 2016 at 3:17 AM, Vimal Kumar <vimal7370@xxxxxxxxx> wrote:
> Hi,
>
> [ceph@ceph1 my-cluster]$ ceph -v
> ceph version 10.2.2 (45107e21c568dd033c2f0a3107dec8f0b0e58374)
> [ceph@ceph1 my-cluster]$ rados -p mypool ls
> hello.txt
> [ceph@ceph1 my-cluster]$ rados -p mypool mksnap snap01
> created pool mypool snap snap01
> [ceph@ceph1 my-cluster]$ rados -p mypool lssnap
> 5 snap01 2016.08.21 03:59:28
> 1 snaps
> [ceph@ceph1 my-cluster]$ rados -p mypool listsnaps hello.txt
> hello.txt:
> cloneid snaps size overlap
> head - 13
>
> Is this normal? Why is snap01 not listed in the above output? It is also
> having 'hello.txt', then why does snap01 not feature in the above list? I
> assume 'head' refers to the pool itself?
>
>
> [ceph@ceph1 my-cluster]$ rados -p mypool rm hello.txt
> [ceph@ceph1 my-cluster]$ rados -p mypool ls
> [ceph@ceph1 my-cluster]$ rados -p mypool listsnaps hello.txt
> hello.txt:
> cloneid snaps size overlap
> 5 5 13 []
>
> So, only after removing the object from pool does the snapshot id shows up.
>
>
> [ceph@ceph1 my-cluster]$ rados -p mypool rollback hello.txt snap01
> rolled back pool mypool to snapshot snap01
> [ceph@ceph1 my-cluster]$ rados -p mypool ls
> hello.txt
> [ceph@ceph1 my-cluster]$ rados -p mypool listsnaps hello.txt
> hello.txt:
> cloneid snaps size overlap
> 5 5 13 []
> head - 13
>
> After roll back of the deleted object from snapshot to pool, both snapshot
> id and 'head' are listed! Isn't this same as the first case?

You're sort of mixing paradigms here. The object-level listsnaps
focuses on identifying the specific snapshotted versions of an object
that exist on disk (which works on self-managed snapshots as well as
pool snapshots); the pool-level lssnap shows which pool-wide snapshots
logically exist. When you create a pool snapshot, any subsequent
writes to objects will create snapshotted versions of the objects, but
simply creating a pool snapshot doesn't do anything to them directly.
-Greg

>
> More over, on checking the 'man' page of rados, I realise that 'listsnaps'
> and 'rollback' options are missing. Is there a better / recommended way to
> deal with pool snapshots?

Oh, they probably just didn't get documented. Patches welcome!
_______________________________________________
ceph-users mailing list
ceph-users@xxxxxxxxxxxxxx
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com



[Index of Archives]     [Information on CEPH]     [Linux Filesystem Development]     [Ceph Development]     [Ceph Large]     [Ceph Dev]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [xfs]


  Powered by Linux