Jump to: navigation, search

Cinder


OpenStack Block Storage ("Cinder")

[Cinder on launchpad (including bug tracker and blueprints)]
[Source code]
[Developer docs]

Mission Statement

To implement services and libraries to provide on demand, self-service access to Block Storage resources. Provide Software Defined Block Storage via abstraction and automation on top of various traditional backend block storage devices.

Description

Cinder is a Block Storage service for OpenStack. It's designed to allow the use of either a reference implementation (LVM) to present storage resources to end users that can be consumed by the OpenStack Compute Project (Nova). The short description of Cinder is that it virtualizes pools of block storage devices and provides end users with a self service API to request and consume those resources without requiring any knowledge of where their storage is actually deployed or on what type of device.

Related projects

  • Python Cinder client
  • Block Storage API documentation

What is Cinder ?

Cinder provides an infrastructure for managing volumes in OpenStack. It was originally a Nova component called nova-volume, but has become an independent project since the Folsom release.

Reasoning:

  1. Nova is currently a very large project; managing all of the dependencies in linkages of services within Nova can make the ability to advance new features and functionality very difficult.
  2. As a result of the many components and dependencies in Nova, it's difficult for anybody to really have a complete view of Nova and to be a true expert. This makes the job of core team member on Nova very difficult, and inhibits good thorough reviews of bug and blueprint submissions.
  3. Block storage is a critical component of OpenStack, as such it warrants focused and dedicated attention.
  4. Having Block Storage as a dedicated core project in OpenStack enables the ability to greatly improve functionality and reliability of the block storage component of OpenStack

Documents:

Minimum Driver Features

See driver dev docs

Keeping consistant with multi backend

In order to maintain consistency with multi backend, do not directly use FLAGS.my_flag, instead use the self.configuration that is provided to the volume drivers. If this does not exist, look @ lvm.py and add it to your driver. using FLAGS.my_flag instead of self.configuration.my_flag will cause multi backend to not work properly. Multi backend relies on the configurations to be within a specific config group in the config file, and the self.configuration abstracts that away from the drivers.

Keeping informed and providing CONSTRUCTIVE INPUT

The Cinder team currently meets on a weekly basis in #openstack-meeting at 16:00 UTC on Wednesdays. I try to keep the meetings wiki agenda page http://wiki.openstack.org/CinderMeetings up to date and follow it. Also keep in mind that anybody is able to add/suggest agenda items via the meeting wiki page.

Of course, there's also IRC... a number of us monitor #openstack-cinder or you can always send a PM to jgriffith (that's me)

Concerns from the community:

Compatibility and Migration:

There has been a significant amount of concern raised regarding "compatibility"; unfortunately this seems to mean different things to different people. For those that haven't looked at the Cinder code or tried a demo in devstack, here are some question/answers:

  • Do the same nova client commands I use for volumes today still work the same? YES
  • Do the same euca2ools that I use for volumes today still work the same? YES
  • Does block storage still work the same as it does today in terms of LVM, iSCSI and the drivers that are curently in place? YES
  • Are the associated database tables the same as they are in the current nova volume code? For the most part YES, all volume related tables and columns are migrated, non-volume related tables however are not present
  • Does it use the same nova database as we use today? No, it does require a new independent database
  • Are you going to implement cinder with complete disregard for my current install and completely change everything out from under me? ABSOLUTELY NOT
  • Are you going to test migrating from nova-vol to Cinder? YES
  • Are those migration tests going to be done just using fakes/unit tests? NO, we would require running setups, most likely devstack
  • Are you planning to provide migration scripts/tools to move from nova to cinder? YES

Additional thoughts to keep in mind:

  • The Cinder core team is fortunate enough to have a number of members who currently work for companies that are using OpenStack in production environments. There is a strong representation and the concerns of Providers is in fact a major consideration
  • The goal is NOT to throw away nova-volume as it is today, but to separate it, focus on it and improve it.
  • Migration is one of the top priorities for introduction of Cinder into Folsom (regardless of whether nova-volume is still in place or not). This is something that is just considered a part of the requirements for the project.

Cinder Core Drivers

For a list of the core drivers in each OpenStack release and the volume operations they support, see https://wiki.openstack.org/wiki/CinderSupportMatrix

Notes About Submitting Patches

Everyone is welcome to sign the CLA and submit code. Please be sure you familiarize yourself with the "how to contribute guide" (https://wiki.openstack.org/wiki/How_To_Contribute#If_you.27re_a_developer).

Keep in mind, there is a disproportionate number of submitters to reviewers. YOU can help with this!! Anybody is welcome to review patches, jump in, give a review. It's a great way to learn more about the code and to help you make better submissions in the future. It also helps your karma, when you submit a patch if you're an active reviewer core team members are more likely to notice your patch and give it some attention before some others.

Cinder Plugins

How to submit a plugin/driver: https://wiki.openstack.org/wiki/Cinder/how-to-contribute-a-driver

Cinder Plugin/Driver certification page: https://wiki.openstack.org/wiki/Cinder/certified-drivers

The following plugins (from other sources) are avaialble for this project

Configuring devstack to use your driver and backend

One of the things you'll be required to do when submitting a new driver is running your backend and driver in a devstack environment and executing the tempest volume tests against it. Currently we provide a driver_cert wrapper (mentioned in the how-to-contribute-a-driver section). One thing that causes some confusion is how do I configure devstack to use my backend device. It used to be that your driver info would have to be added to lib/cinder in devstack to set your options. We then created a cinder/plugin module in devstack. Fortunately though it's MUCH easier than that. For *most* drivers, the only changes that are made consist of cinder.conf file changes. That can easily be accomplished by using devstacks local.conf file (more info here: http://devstack.org/configuration.html). For more complex actions (like the need to install packages etc, the plugin directory in devstack can be used). An example of what this file would look like to add driver FOO is shown below, the default localrc section is included for completeness, but the section of interest is the post-config cinder.conf section:

[[local|localrc]]
:# Passwords
ADMIN_PASSWORD=password
MYSQL_PASSWORD=password
RABBIT_PASSWORD=password
SERVICE_PASSWORD=password
SERVICE_TOKEN=password
SCREEN_LOGDIR=/opt/stack/logs
HOST_IP=172.16.140.246
disable_service n-net
enable_service q-svc
enable_service q-agt
enable_service q-dhcp
enable_service q-l3
enable_service q-meta
enable_service neutron

# These options define expected driver capabilities
TEMPEST_VOLUME_DRIVER=foo
TEMPEST_VOLUME_VENDOR="Foo Inc"
TEMPEST_STORAGE_PROTOCOL=iSCSI

# These options allow you to specify a branch other than "master" be used
CINDER_REPO=https://review.openstack.org/openstack/cinder
CINDER_BRANCH=refs/changes/83/72183/4

# Disable security groups entirely
Q_USE_SECGROUP=False
LIBVIRT_FIREWALL_DRIVER=nova.virt.firewall.NoopFirewallDriver
CINDER_SECURE_DELETE=False

[[post-config|$CINDER_CONF]]
volume_driver = cinder.volume.drivers.foo.FooDriver
foos_var = something
another_foo_var = something-else