Configuring InfiniBox volume driver for OpenStack Cinder

Follow

Prerequisites

  1. Install OpenStack.
  2. Install the InfiniBox volume driver for OpenStack Cinder.
  3. Nova, Cinder and ESX hosts must be prepared to work with InfiniBox.

Configuring the volume driver using infini-openstack command-line tool

infini-openstack is a command line tool for adding the InfiniBox system and volume backend types to Cinder's configuration file.

Since infini-openstack re-writes Cinder's configuration file, it deletes comments inside it. If you want to keep the comments, you add the requires changes manually, as explained here.

For cinder to provision volume within InfiniBox, one has to:

  1. Configure one or more InfiniBox volume-backend types (Each volume-backend type is associated with an <Infinibox system>/<pool> pair).
  2. Enable those volumes-backend types (i.e configure Cinder to load the driver for each pool).

For example, in order to configure a volume-backend type, one has to run:

    infini-openstack --commit volume-backend set <Infinibox-management-address> <username> <password> <pool-name>

where the flag "--commit" allows the script to override Cinder's configuration file. The list of the volume-backend types can be viewed using:

    infini-openstack volume-backend list

where each row of the output corresponds to a volume-backend type, and contains the following information:

+------------------+----------+---------+---------------+---------------+--------------------+---------+---------------+
|     address      | username | enabled |    status     | system serial |    system name     | pool id |  pool name    |
+------------------+----------+---------+---------------+---------------+--------------------+---------+---------------+

Using the pool id obtained from the above output, one can then enable a specific volume-backend:

    infini-openstack --commit volume-backend enable <management-address> <pool-id>

In addition, if iSCSI is enabled in the host, but fibrechannel should be used for this volume backend, please run:

    infini-openstack volume-backend set-protocol fc <management-address> <pool-id>

To get more details about infini-openstack command line interface, run:

    infini-openstack --help

For the changes to take effect, the Cinder volume service should be restarted using:

    service openstack-cinder-volume restart

Configuring the volume driver manually

This step is not necessary if you are already using infini-openstack

Cinder's configuration file is located at "/etc/cinder/cinder.conf". For each volume-backend type, one has to append a section to Cinder's configuration file:

[infinibox-12345-pool-6789] # section name of the form: infinibox-{infinibox system serial}-pool-{pool id}
 
volume_driver = infinidat_openstack.cinder.InfiniboxVolumeDriver # do not change!
san_ip = <infinibox management address or hostname>
infinidat_pool_id = <pool id inside this infinibox> # the pool id can be retrieved using the infinihost CLI tool
san_login = <infinibox user name>
san_password = <infinibox password>
infinidat_provision_type = <provision type> # thin/thick, default: [thick]
volume_backend_name = <display name for openstack dashboard>
infinidat_prefer_fc = True # fc or iscsi
# infinidat_preferred_iscsi_network_space = <name> # required if the system has more than one iSCSI network space
 

To enable one or more volume backend type, you should edit the following line in the default section of Cinder's configuration file:

[DEFAULT]
 
enabled_backends = infinibox-20011-pool-3716,infinibox-20012-pool-2582

where each element is a section name corresponding to a volume-backend type. For the changes to take effect, the Cinder volume service should be restarted using:

    service openstack-cinder-volume restart

Once that completes, you need to create the volume type in Cinder database by running:

	cinder type-create [infinibox-12345-pool-6789] # section name of the form: infinibox-{infinibox system serial}-pool-{pool id}




Comments

Powered by Zendesk