Hi Liu,
Sorry for the late reply; I have had a very busy week. :)
On Thu, 1 Nov 2012, liu yaqi wrote:
> Dear Mr.Weil
>
> I am a student of Institute of Computing Technology, Chinese Academy of
> Sciences, and I am learning the realization of snapshot in ceph system.
> There are sometings that puzzle me, and I want to ask you some questions.
> First question, there is a command "ceph osd cluster_snap {name}", but i
> cannot found the complete realization process, and I want to ask is the
> snapshot for the whole cluster has been realized?
The idea was to have a low-level cluster-wide snapshot that could be used
for recovery if ceph itself went haywire and corrupted itself. The idea
would be for the OSDs to create btrfs-level snapshots of their data. It
was never completely implemented, though, and the OSD bits have mostly
been removed. In particular, we never made a way for the monitor state to
be checkpointed, which would be necessary for the whole scheme to work
properly.
> Second question, there
> seems to be snapshots for pools and images. I want to ask what does pool and
> image mean? Is an image means an osd?
Lots of different snapshots:
- librados lets you do 'selfmanaged snaps' in its API, which let an
application control which snapshots apply to which objects.
- you can create a 'pool' snapshot on an entire librados pool. this
cannot be used at the same time as rbd, fs, or the above 'selfmanaged'
snaps.
- rbd let's you snapshot block device images (by usuing the librados
selfmanaged snap API).
- the ceph file system let's you snapshot any subdirectory (again
utilizing the underlying RADOS functionality).
> Third question, in the "mds" folder,
> there are files like "snapserver" "MClientSnap" and so on, is there files
> are used to snapshot the metadata only?
Yes.
> Does they have some relationship
> with the pool or image snapshots?
Not really.
> The last question, is there snapshots
> for a file path in the ceph? Or, the snapshots must be done on metadata and
> data separately?
For the file system, you create a snapshot on a directory and it affects
all files in that directory and beneath it, including the data in those
files.
Hope that helps!
sage
> If you would kind enough to help me on the above questions, I will be
> grateful. And I am looking forward to your reply.
>
> With best wishes for you.
>
> Yours, YaqiLiu
>