Installing and Configuring OpenStack in Oracle® Solaris 11.2

Exit Print View

Updated: April 2015
 
 

Installing Cinder

The Cinder configuration must specify at least the following information:

  • Authorization information to authenticate with Keystone.

  • The class of volumes to be created.

How to Install and Configure Cinder

  1. Install the Cinder package.
    controller# pkg install cinder
  2. Specify authentication configuration information.

    Uncomment and set the following parameters in the /etc/cinder/api-paste.ini file. These parameters specify the location of the Keystone API service and the Cinder authentication information.

    auth_uri = http://controller-name:5000/v2.0
    identity_uri = http://controller-name:35357
    admin_tenant_name = service
    admin_user = cinder
    admin_password = cinder-password
  3. Specify the classes of volumes that the Cinder volume service should create.

    In the /etc/cinder/cinder.conf file, uncomment the appropriate volume_driver parameter. The following four classes of volumes are supported:

    ZFSVolumeDriver

    Supports creation of local volumes for use by Nova on the same node as the Cinder volume service.

    ZFSISCSIDriver

    Supports creation and export of iSCSI targets for use by remote Nova compute nodes.

    ZFSFCDriver

    Supports creation and export of Fibre Channel LUNs for use by remote Nova compute nodes.

    ZFSSAISCSIDriver

    Supports creation and export of iSCSI targets from a remote Oracle ZFS Storage Appliance for use by remote Nova compute nodes. Additional parameters for this driver must be set in the /etc/cinder/cinder.conf file.

    In the example described in this chapter, iSCSI is used to provide volumes for use by Nova instances. Comment out the default selection of ZFSVolumeDriver, and uncomment the ZFSISCSIDriver selection.

    # Driver to use for volume creation (string value)
    # The local ZFS driver provides direct access to ZFS volumes that it
    # creates. The other listed drivers provide access to ZFS volumes via
    # iSCSI or Fibre Channel and are suitable for cases where block storage
    # for Nova compute instances is shared.
    #volume_driver=cinder.volume.drivers.solaris.zfs.ZFSVolumeDriver
    volume_driver=cinder.volume.drivers.solaris.zfs.ZFSISCSIDriver
    #volume_driver=cinder.volume.drivers.solaris.zfs.ZFSFCDriver
    #volume_driver=cinder.volume.drivers.zfssa.zfssaiscsi.ZFSSAISCSIDriver
  4. Set additional configuration parameters.

    Uncomment and set the following parameters in the /etc/cinder/cinder.conf file. These parameters specify the location of the Glance API service, the corresponding database for Cinder, and the RabbitMQ service.

    glance_host=controller-name
    sql_connection=mysql://cinder:cinder@controller-name/cinder
    rabbit_host=controller-name
    volume_driver=cinder.volume.drivers.solaris.zfs.ZFSISCSIDriver
  5. If iSCSI targets will be configured, enable the corresponding SMF services.
    controller# svcadm enable iscsi/target stmf
  6. Enable the Cinder SMF services.
    controller# svcadm enable cinder-db
    controller# svcadm enable cinder-api cinder-scheduler
    controller# svcadm enable cinder-volume:default cinder-volume:setup

See also

See also How to Build OpenStack Block Storage on ZFS.

How to Configure the ZFS Storage Appliance iSCSI Cinder Driver

The Oracle ZFS Storage Appliance iSCSI Cinder driver enables the Oracle ZFS Storage Appliance (ZFSSA) to be used seamlessly as a block storage resource for Cinder. The driver provides the ability to create iSCSI volumes that can be allocated by a Cinder server to any virtual machine instantiated by the Nova service. The driver is delivered by the cloud/openstack/cinder package. Your appliance must be running at least ZFSSA software release 2013.1.2.0.

Before You Begin

Configure a pool on the Oracle ZFS Storage Appliance. You can choose to use a preexisting pool.

  1. Run the workflow cinder.akwf.

    You can either use an existing user or create a new user with role authorizations for performing Cinder driver operations.

    The cinder.akwf workflow performs the following tasks:

    • Creates the user if the user does not exist.

    • Sets role authorizations for performing Cinder driver operations.

    • Enables the RESTful service if the service is currently disabled.

    You can run the workflow from the Command Line Interface (CLI) or from the Browser User Interface (BUI) of your appliance.

    • Run the workflow from the CLI.
      zfssa:maintenance workflows> download
      zfssa:maintenance workflows download (uncommitted)> show
      Properties:
                                url = (unset)
                               user = (unset)
                           password = (unset)
      
      zfssa:maintenance workflows download (uncommitted)> set url="url to the cinder.akwf file"
                                url = "url to the cinder.akwf file"
      zfssa:maintenance workflows download (uncommitted)> commit
      Transferred 2.64K of 2.64K (100%) ... done
      
      zfssa:maintenance workflows> ls
      Properties:
                         showhidden = false
      
      Workflows:
      
      WORKFLOW     NAME                                      OWNER SETID ORIGIN              VERSION
      workflow-000 Clear locks                               root  false Oracle Corporation  1.0.0
      workflow-001 Configuration for OpenStack Cinder Driver root  false Oracle Corporation  1.0.0
      
      zfssa:maintenance workflows> select workflow-001
      
      zfssa:maintenance workflow-001 execute (uncommitted)> set name=openstack
                               name = openstack
      zfssa:maintenance workflow-001 execute (uncommitted)> set password=openstack-password
                           password = ********
      zfssa:maintenance workflow-001 execute (uncommitted)> commit
      User openstack created.
    • Run the workflow from the BUI.
      1. Select Maintenance → Workflows, and use the plus icon to upload a new workflow.
      2. Click the Browse button, and select the cinder.akwf file.
      3. Click the UPLOAD button to finish uploading the workflow.
      4. Click on the new row that appears on the BUI Workflows page to run the Cinder driver workflow.

        The workflow prompts for a user name and password. This user name and password will also be used in the cinder.conf file as zfssa_auth_user and zfssa_auth_password.

  2. Set parameters in the cinder.conf file.

    Specify the following required properties in the cinder.conf file:

    • volume_driver – Make sure cinder.volume.drivers.zfssa.zfssaiscsi.ZFSSAISCSIDriver is uncommented. Make sure the other three selections are commented out.

    • zfssa_host – The name or IP address of the ZFSSA management host.

    • zfssa_auth_user – The user name of the Cinder user on the ZFSSA.

    • zfssa_auth_password – The password of the Cinder user on the ZFSSA.

    • zfssa_pool – The pool to be used to allocate volumes.

    • zfssa_target_portal – The ZFSSA iSCSI target portal (data-ip:port). The default port is 3260.

    • zfssa_project – The name of the ZFSSA project. If the project does not exist on the appliance, a project with that name is created by the driver at startup time. This project contains all the volumes created by the driver. Additional ZFSSA properties are provided for setting up volume characteristics (for example, block size) and access (for example, initiators, targets, security).

    • zfssa_initiator_group – The name of the initiator group. If the initiator group does not exist on the appliance, an initiator group with that name is created by the driver at startup time. If you want to use the default initiator group, set the value of this parameter to default. The default initiator group can be useful for evaluation purposes. The default initiator group should not normally be used because it can result in exposure of the volumes to unwanted or conflicting initiators.

    • zfssa_target_interfaces – The ZFSSA iSCSI target network interfaces. Use the following command to see the interfaces:

      zfssa:configuration net interfaces> show
      Interfaces:
      
        INTERFACE STATE CLASS LINKS    ADDRS          LABEL
        e1000g0   up    ip    e1000g0  1.10.20.30/24  Untitled Interface
    • connection – Change connection to sql_connection.

      Locate the following line:

      connection=mysql://cinder:cinder...

      Modify this line as shown below:

      sql_connection=mysql://cinder:cinder...
  3. Ensure the ZFSSA iSCSI service is online.

    If the ZFSSA iSCSI service is not online, use either the BUI or the CLI in the appliance to enable it. The following example shows using the CLI in the appliance:

    zfssa:> configuration services iscsi
    zfssa:configuration services iscsi> enable
    zfssa:configuration services iscsi> show
    Properties:
    <status> = online
    ...
  4. Enable the Cinder volume SMF services.
    controller# svcadm enable cinder-volume:default cinder-volume:setup