[Openstack] [OpenStack] How to add a RBD volume snapshot rollback operation to Cinder
Changqian Zuo
dummyhacker85 at gmail.com
Thu Jan 2 08:42:02 UTC 2014
在 2014-01-02四的 16:01 +0800,Haomai Wang写道:
> On Thu, Jan 2, 2014 at 3:38 PM, Changqian Zuo <dummyhacker85 at gmail.com> wrote:
> > Hi,
> >
> > First time mailing to a list.
> >
> > I'm trying to add a RBD volume snapshot rollback operation to Cinder.
> > I've just got through WSGI part of Cinder API code and have read some
> > pieces of Cinder Volume. Now there is not much time for me to complete
> > the whole code base (with Ceph driver) very carefully, I need some
> > advice.
> >
> > Is adding a Extension Controller the most suitable way to do this? How
> > to deal with snapshot and volume state transformation, would it affect
> > other part of Cinder codes? What parts of Cinder codes I should pay
> > special attention?
> >
> > Many thanks.
> >
> > Some background information:
> >
> > We're planning to use Cinder bootable volume (Ceph RBD as backend) as
> > instance root disk in my company's OpenStack environment. Creating a
> > volume snapshot from image, and then use this snapshot to spawn instance
> > root volumes.
>
> From your description, it seemed that you can use rbd as nova backend directly.
>
> nova.conf:
> libvirt_image_type='rbd'
>
> more options can be find at nova/virt/libvirt/imagebackend.py
>
> >
> > To backup volume state, I've thought of Cinder-Backup service (still
> > need to add a in-use backup for Cinder), but it takes too much space (a
> > 80G volume would take at least 248G space for base backup image with x3
> > Ceph replication ratio). The other way is volume snapshot, but in this
> > case when restoring volume data, I have to create a new volume from
> > snapshot, destroy the original instance (there's no API to change a
> > instance's bootable volume), and create a new instance from new volume.
> >
> > The old volume can not be removed, for a snapshot is referencing to it
> > (the snapshot must be kept). If I do this again and again, there would
> > be many snapshots referencing to many different volumes, and I have to
> > keep these volumes (not used elsewhere), which is a mess.
> >
> >
> >
> > _______________________________________________
> > Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
> > Post to : openstack at lists.openstack.org
> > Unsubscribe : http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>
>
>
Thanks,
I do know in Havana release, we could use RBD as Nova image storage.
There are reasons I choose such a way to launch an instance. Firstly,
our company are moving from XCP to OpenStack, we have an old framework
and business mode to manage Xen instance and VDIs, so hoping to fit
OpenStack into this framework. The decision is made by my boss.
Secondly, I myself would prefer this way, for it would be to easy to
manage root disk, for example, I could use Cinder Backup service to do
some remote backup. Using nova image, the root disk may not be easily
seen.
More information about the Openstack
mailing list