Red Hat OpenStack Platform-17.1-Deploying A Custom Block Storage Back end-en-US
Red Hat OpenStack Platform-17.1-Deploying A Custom Block Storage Back end-en-US
Deploy a custom, non-integrated, Block Storage back end in a Red Hat OpenStack
Platform overcloud
OpenStack Team
[email protected]
Legal Notice
Copyright © 2024 Red Hat, Inc.
The text of and illustrations in this document are licensed by Red Hat under a Creative Commons
Attribution–Share Alike 3.0 Unported license ("CC-BY-SA"). An explanation of CC-BY-SA is
available at
http://creativecommons.org/licenses/by-sa/3.0/
. In accordance with CC-BY-SA, if you distribute this document or an adaptation of it, you must
provide the URL for the original version.
Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert,
Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
Red Hat, Red Hat Enterprise Linux, the Shadowman logo, the Red Hat logo, JBoss, OpenShift,
Fedora, the Infinity logo, and RHCE are trademarks of Red Hat, Inc., registered in the United States
and other countries.
Linux ® is the registered trademark of Linus Torvalds in the United States and other countries.
XFS ® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States
and/or other countries.
MySQL ® is a registered trademark of MySQL AB in the United States, the European Union and
other countries.
Node.js ® is an official trademark of Joyent. Red Hat is not formally related to or endorsed by the
official Joyent Node.js open source or commercial project.
The OpenStack ® Word Mark and OpenStack logo are either registered trademarks/service marks
or trademarks/service marks of the OpenStack Foundation, in the United States and other
countries and are used with the OpenStack Foundation's permission. We are not affiliated with,
endorsed or sponsored by the OpenStack Foundation, or the OpenStack community.
Abstract
Deploy a back end for the Block Storage service (cinder) in a Red Hat OpenStack Platform
(RHOSP) overcloud, which is not yet fully integrated into the RHOSP director.
Table of Contents
Table of Contents
. . . . . . . . . .OPEN
MAKING . . . . . . SOURCE
. . . . . . . . . .MORE
. . . . . . .INCLUSIVE
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3. . . . . . . . . . . . .
. . . . . . . . . . . . . FEEDBACK
PROVIDING . . . . . . . . . . . . ON
. . . .RED
. . . . .HAT
. . . . .DOCUMENTATION
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. . . . . . . . . . . . .
. . . . . . . . . . . 1.. .DEPLOYING
CHAPTER . . . . . . . . . . . . .A
. . BLOCK
. . . . . . . . STORAGE
. . . . . . . . . . . SERVICE
. . . . . . . . . .CUSTOM
. . . . . . . . . .BACK
. . . . . . END
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5. . . . . . . . . . . . .
.CHAPTER
. . . . . . . . . . 2.
. . UNDERSTANDING
. . . . . . . . . . . . . . . . . . . .CUSTOM
. . . . . . . . . .BACK
. . . . . . ENDS
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6. . . . . . . . . . . . .
2.1. REQUIREMENTS 6
2.2. UNDERSTANDING THE CONFIGURATION PROCESS 6
. . . . . . . . . . . 3.
CHAPTER . . CREATING
. . . . . . . . . . . . THE
. . . . .CUSTOM
. . . . . . . . . .BACK
. . . . . . END
. . . . . ENVIRONMENT
. . . . . . . . . . . . . . . . .FILE
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7. . . . . . . . . . . . .
. . . . . . . . . . . 4.
CHAPTER . . .DEPLOYING
. . . . . . . . . . . . .THE
. . . . .CONFIGURED
. . . . . . . . . . . . . . .BACK
. . . . . . ENDS
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9. . . . . . . . . . . . .
. . . . . . . . . . . 5.
CHAPTER . . TESTING
. . . . . . . . . . THE
. . . . . CONFIGURED
. . . . . . . . . . . . . . .BACK
. . . . . . ENDS
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
..............
. . . . . . . . . . . 6.
CHAPTER . . .CONFIGURATION
. . . . . . . . . . . . . . . . . . FROM
. . . . . . . SAMPLE
. . . . . . . . . .ENVIRONMENT
. . . . . . . . . . . . . . . . FILE
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11. . . . . . . . . . . . .
1
Red Hat OpenStack Platform 17.1 Deploying a custom Block Storage back end
2
MAKING OPEN SOURCE MORE INCLUSIVE
3
Red Hat OpenStack Platform 17.1 Deploying a custom Block Storage back end
1. Ensure that you are logged in to Jira. If you do not have a Jira account, create an account to
submit feedback.
2. Click the following link to open a the Create Issue page: Create Issue
3. Complete the Summary and Description fields. In the Description field, include the
documentation URL, chapter or section number, and a detailed description of the issue. Do not
modify any other fields in the form.
4. Click Create.
4
CHAPTER 1. DEPLOYING A BLOCK STORAGE SERVICE CUSTOM BACK END
The Openstack environment that director creates is called the overcloud. The overcloud contains all the
components that provide services to end users, including Block Storage. This document provides
guidance about how to deploy a custom back end to the Block Storage service (cinder) on the
overcloud. By default, the Block Storage service is installed on Controller nodes.
Prerequisites
You are familiar with Block Storage concepts and configuration. For more information about
Block Storage, see Block Storage and Volumes in the Configuring persistent storage guide.
WARNING
This procedure has been tested successfully in limited use cases. Ensure that you
test your planned deployment on a non-production environment first. If you have
any questions, contact Red Hat support.
5
Red Hat OpenStack Platform 17.1 Deploying a custom Block Storage back end
Some integrated storage appliances support only a single-instance back end. For example, with the pre-
configured director files for Dell Storage Center, you can only deploy a single back end. If you want to
deploy multiple back end instances of this appliance, you need a custom configuration.
Although you can manually configure the Block Storage service by directly editing the
/etc/cinder/cinder.conf file on the node where the Block Storage service is located, the director
overwrites your configuration when you run the openstack overcloud deploy command. For more
information, see Deploying the configured back ends . Deploy the Block Storage back end with the
director to ensure that your settings persist through overcloud deployments and updates.
If your back end configuration is fully integrated you can edit and invoke the packaged environment files.
However, for custom back ends, you must write your own environment file. This document includes the
annotated /home/stack/templates/custom-env.yaml file that you can edit for your deployment, see
Configuration from sample environment file .
This sample file is suitable for configuring the Block Storage service to use two NetApp back ends. For
more information about environment files, see Including environment files in an overcloud deployment in
the Installing and managing Red Hat OpenStack Platform with director guide.
2.1. REQUIREMENTS
The following additional prerequisite conditions must apply to your environment to configure custom
Block Storage back ends:
If you are using third-party back end appliances, you have configured them as storage
repositories.
You have deployed the overcloud with director with the instructions in Installing and managing
Red Hat OpenStack Platform with director.
You have the username and password of an account with elevated privileges. You can use the
same stack user account that you created to deploy the overcloud.
You have already planned the resulting configuration that you want for the Block Storage back
end in /etc/cinder/cinder.conf.
Creating the environment file. For more information, see Creating the custom back end
environment file.
Deploying the configured back ends. For more information, Deploying the configured back
ends.
Testing the configured back end. For more information, Testing the configured back ends .
6
CHAPTER 3. CREATING THE CUSTOM BACK END ENVIRONMENT FILE
The following sample environment file defines two NetApp back ends, netapp1 and netapp2:
/home/stack/templates/custom-env.yaml
parameter_defaults: # 1
CinderEnableIscsiBackend: false
CinderEnableRbdBackend: false
CinderEnableNfsBackend: false
NovaEnableRbdBackend: false
GlanceBackend: file # 2
ControllerExtraConfig: # 3
cinder::config::cinder_config:
netapp1/volume_driver: # 4
value: cinder.volume.drivers.netapp.common.NetAppDriver
netapp1/netapp_storage_family:
value: ontap_7mode
netapp1/netapp_storage_protocol:
value: iscsi
netapp1/netapp_server_hostname:
value: 10.35.64.11
netapp1/netapp_server_port:
value: 80
netapp1/netapp_login:
value: root
netapp1/netapp_password:
value: p@$$w0rd
netapp1/volume_backend_name:
value: netapp1
netapp2/volume_driver: # 5
value: cinder.volume.drivers.netapp.common.NetAppDriver # 6
netapp2/netapp_storage_family:
value: ontap_7mode
netapp2/netapp_storage_protocol:
value: iscsi
netapp2/netapp_server_hostname:
value: 10.35.64.11
netapp2/netapp_server_port:
value: 80
netapp2/netapp_login:
value: root
netapp2/netapp_password:
value: p@$$w0rd
netapp2/volume_backend_name:
value: netapp2
cinder_user_enabled_backends: ['netapp1','netapp2'] # 7
7
Red Hat OpenStack Platform 17.1 Deploying a custom Block Storage back end
1 The following parameters are set to false, which disables other back end types:
CinderEnableNfsBackend: NFS.
2 The GlanceBackend parameter sets what the Image service uses to store images. The following
values are supported:
3 ControllerExtraConfig defines custom settings that are applied to all Controller nodes. The
cinder::config::cinder_config class means the settings must be applied to the Block Storage
(cinder) service.
7 The cinder_user_enabled_backends class sets and enables custom back ends. Use this class only
for user-enabled back ends, specifically, those defined in the cinder::config::cinder_config class.
Do not use cinder_user_enabled_backends to list back ends that you can enable natively with
director. These include Red Hat Ceph, NFS, and single back ends for supported NetApp or Dell
appliances. For example, if you enable a Red Hat Ceph back end, do not list it in
cinder_user_enabled_backends, enable it by setting CinderEnableRbdBackend to true.
NOTE
For more information about defining a Red Hat Ceph back end for OpenStack Block
Storage, see Deploying Red Hat Ceph Storage and Red Hat OpenStack Platform
together with director.
8
CHAPTER 4. DEPLOYING THE CONFIGURED BACK ENDS
Procedure
2. Run the following command to deploy the custom back end configuration:
IMPORTANT
If you passed any extra environment files when you created the overcloud, pass them
again here using the -e option to avoid making undesired changes to the overcloud. For
more information, see Modifying the overcloud environment in the Installing and
managing Red Hat OpenStack Platform with director guide.
9
Red Hat OpenStack Platform 17.1 Deploying a custom Block Storage back end
Procedure
1. Run the following command as the stack user to load the environment variables defined in
home/stack/overcloudrec:
$ source /home/stack/overcloudrc
NOTE
For more information, see Accessing the overcloud in the Installing and managing
Red Hat OpenStack Platform with director guide.
2. Create a volume type for each back end. Log in to the Controller node of the overcloud as the
stack user and run the following command:
These commands create the volume types backend1 and backend2, one for each back end
that is defined with the cinder::config::cinder_config class of the environment file that you
created.
3. Map each volume type to the volume_backend_name of a back end that is enabled with the
cinder_user_enabled_backends class of the environment file that you created The following
commands map the volume type backend1 to netapp1 and backend2 to netapp2:
4. Run the following command to test that it is possible to create a back end on netapp1 by
invoking the backend1 volume type:
5. Create a similar volume on the netapp2 back end by invoking the backend2 volume type:
10
CHAPTER 6. CONFIGURATION FROM SAMPLE ENVIRONMENT FILE
enabled_backends = netapp1,netapp2
[netapp1]
volume_backend_name=netapp_1
volume_driver=cinder.volume.drivers.netapp.common.NetAppDriver
netapp_login=root
netapp_storage_protocol=iscsi
netapp_password=p@$$w0rd
netapp_storage_family=ontap_7mode
netapp_server_port=80
netapp_server_hostname=10.35.64.11
[netapp2]
volume_backend_name=netapp_2
volume_driver=cinder.volume.drivers.netapp.common.NetAppDriver
netapp_login=root
netapp_storage_protocol=iscsi
netapp_password=p@$$w0rd
netapp_storage_family=ontap_7mode
netapp_server_port=80
netapp_server_hostname=10.35.64.11
11