Score:0

extract openstack instances' volume from ceph

fo flag

I have an OpenStack-kolla environment with the Ceph backend. I've configured my cinder backend with NFS. I can create a Backup with Cinder from all instances and store them on NFS. In this case, I don't want to change the Cinder backend to the Ceph but I wonder if there is a way to have access to all Instance volumes on the Ceph like a file and then extract/Download those files from ceph. what exactly I need is, for example, I have an instance with one attached volume. I want to extract this volume from ceph and keep it, and be able to export that volume to another Openstack. I know that there are some ways to migrate one instance to another Openstack but I want to have access to the Volumes in the Ceph. Thank you in advance.

Score:0
us flag

Although I don't understand why you mention NFS, of course there are ways to export rbd images from Ceph with the appropriate keyrings and permissions. Here's an example to export a volume (containing a glance image) to local file:

root@control01:~# rbd --id cinder -p volumes export volume-dd40908f-52ff-4f47-bb06-e5976ac63cb4 test-volume
Exporting image: 100% complete...done.

root@control01:~# file test-volume 
test-volume: DOS/MBR boot sector

To import an image file into Ceph you can use rbd import:

root@control01:~# rbd --id cinder import test-volume volumes/test-volume

Check the docs and man pages for more information.

sina nasiri avatar
fo flag
Thank you so much. it worked for me.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.