Skip to content

Latest commit

 

History

History
46 lines (36 loc) · 1.33 KB

README.md

File metadata and controls

46 lines (36 loc) · 1.33 KB

ceph-export

Simple app to export rbd images from a ceph pool, based on the last snapshot.

$ ./export.py --help
Usage: export.py [OPTIONS] POOL [IMAGES]...

  Exports rbd images in POOL to vmdk, based on the last snapshot.

Options:
  --path TEXT           Path where to store the exported images.
  --image-pattern TEXT  Pattern to filter the images.
  --snap-pattern TEXT   Pattern to filter the snapshots.
  --debug / --no-debug  Debug and dry-run mode.
  --help                Show this message and exit.

Example: Export two rbd images to /srv/tank/vmdk

$ ./export.py pve-images vm-100-disk-1 vm-101-disk-1 --path=/srv/tank/vmdk
$ ls -al /srv/tank/vmdk
[email protected]
[email protected]

Example: Export all rbd images in pool pve-images to /srv/tank/vmdk

$ ./export.py pve-images --path=/srv/tank/vmdk
$ ls -al /srv/tank/vmdk
[email protected]
[email protected]
[email protected]
...

Example: Export two rbd images to /srv/tank/qcow2 using the qcow2 format

$ ./export.py pve-images vm-100-disk-1 vm-101-disk-1 --path=/srv/tank/qcow2 --format=qcow2
$ ls -al /srv/tank/qcow2
[email protected]
[email protected]