Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- This is based on http://ceph.com/dev-notes/incremental-snapshots-with-rbd/ which is incomplete (missing the initial send step).
- make sure there is an rbd to mount (-l also lists snapshots/clones):
- rbd ls -l
- put some files there (this assumes it is already mounted)::
- cd /mnt/ceph/foo/
- echo snapshot test file1 - before snapshots > snaptest1
- snapshot it as "snap1":
- rbd snap create rbd/foo@snap1
- clone it to another new rbd:
- # unlike "import", "import-diff" does not create an image automatically, so we create one first
- sudo rbd create foo-bak --size 4096
- rbd export-diff rbd/foo@snap1 - | rbd import-diff - rbd/foo-bak
- put more files there:
- echo snapshot test file2, with first snap already done > snaptest2
- snapshot it snap2:
- rbd snap create rbd/foo@snap2
- do the export and import the changes to the other rbd
- rbd export-diff --from-snap snap1 rbd/foo@snap2 - | rbd import-diff - rbd/foo-bak
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement