PowerVC lets you register several storage drivers directly (called integrated storage devices), but it also supports registering pluggable storage devices. A pluggable storage device is just an OpenStack supported storage device. Any storage device supported by an OpenStack driver can be registered with PowerVC, but the level of functionality that it has within PowerVC depends on the driver. You can run this suite of tests on your driver to determine functionality: PowerVC Test Suite For Pluggable Storage Driver Validation.
Additionally, there are some differences in the availability of PowerVC functions on pluggable and integrated storage devices, as listed in this topic: Functions available on pluggable and integrated storage drivers.
Add a pluggable volume driver
1. Obtain the OpenStack driver installable, documentation, and any dependencies. PowerVC 1.4.2 supports the OpenStack Queens release. If you are running a different version of PowerVC, refer to the Hardware and Software requirements topic in the Knowledge Center to determine the supported release of OpenStack. You can use the dropdown to change to the appropriate version of the topic.
- Check if the OpenStack compatible driver is shipped with PowerVC. On the PowerVC management server, check the
- If the driver exists there after the installation of PowerVC, then it is already available at the correct level.
- If the driver does not exist, then continue with the rest of the steps.
- If the driver is a Cinder community driver, run the git command to clone the stable branch:
git clone --branch stable/queens https://git.openstack.org/openstack/cinder.git
Copy the driver directory and its contents from
- If the storage driver is not in the Cinder community, follow the vendor’s instructions for downloading and installing the storage driver.
2. Review the dependencies listed for the driver. For any dependencies that PowerVC does not meet, install and configure them in accordance with the driver’s instructions.
- To determine the driver’s dependencies, review the OpenStack Cinder driver documentation.
- To determine whether the dependencies are already met by PowerVC, run
rpm -aqand review the output.
3. Prepare a properties file for use with the
powervc-register command by creating a file with a section called backend_defaults, followed by any driver specific key/value pairs. For example, this might be a file for an IBM Storwize
[backend_defaults] san_password = passw0rd san_login = svcuser san_ip = 220.127.116.11 storwize_svc_volpool_name = pool_0
The OpenStack driver documentation might list properties that should be set in /etc/cinder/cinder.conf. Do not modify cinder.conf directly. Instead, put all of the driver specific configuration properties in the properties file that is passed to the command.
Note: Do not set the following properties in the properties file because they will be overridden by the arguments specified on the command line: volume_driver, volume_backend_name, enabled_backends, or host_type.
4. Register the storage driver by running the
powervc-register -o add -r resource_type -d volume_driver -n display_name -p properties_file
The command uses the following parameters:
Use “storage” or “fabric” as the resource type, as appropriate.
The path to the volume driver’s Python class. If the driver exists in the standard location, this value may be documented by the OpenStack driver. Otherwise, it depends on where you placed the module. For example, “cinder.volume.drivers.dell_emc.unity.driver.UnityDriver”.
Optional: The driver’s display name
The file used to specify the device specific configuration properties.
For instructions to use the command, run
Example: Registering a Pure Array storage device
This driver is available in the OpenStack stable branch, so we will add it to PowerVC as a pluggable driver.
Test #git clone --branch stable/queens https://git.openstack.org/openstack/cinder.git Cloning into 'cinder'... remote: Counting objects: 180029, done. remote: Compressing objects: 100% (88683/88683), done. remote: Total 180029 (delta 136675), reused 122162 (delta 81523) Receiving objects: 100% (180029/180029), 62.92 MiB | 8.28 MiB/s, done. Resolving deltas: 100% (136675/136675), done. Test #ls cinder Test # Test #cp cinder/cinder/volume/drivers/pure.py /usr/lib/python2.7/site-packages/cinder/volume/drivers/ Test # Test #cat pure_array.conf [backend_defaults] san_ip = 18.104.22.168 pure_api_token = 5f3f98fd-48c5-194d-99c0-e0299aea66dc Test # Test #powervc-register -o add -r storage -d cinder.volume.drivers.pure.PureFCDriver -n pure_array -p /root/pure_array.conf The Storage Provider 'pure_array' added to PowerVC. Test # Test #powervc-register -o list -r storage Name Display Name Type ==== ============ ==== generic0 pure_array generic Test #
Example: Registering an IBM Storwize driver
This driver is available with every PowerVC installation.
Test #cat storwize.conf [backend_defaults] san_password = passw0rd san_login = svcuser san_ip =22.214.171.124 storwize_svc_volpool_name = powervc_pool Test # Test #powervc-register -o add -r storage -d cinder.volume.drivers.ibm.storwize_svc.storwize_svc_fc.StorwizeSVCFCDriver -n svc-fc-storage -p /root/storwize.conf The Storage Provider 'svc-fc-storage' added to PowerVC. Test # Test #powervc-register -o list -r storage Name Display Name Type ==== ============ ==== generic0 svc-fc-storage generic Test #
Removing a pluggable storage device
To remove a pluggable storage device, you can use the PowerVC user interface or you can use the powervc-register command:
powervc-register -o remove -r storage -n display_name Test #powervc-register -o remove -r storage -n svc-fc-storage The Storage Provider 'svc-fc-storage' removed from PowerVC. Test #
As you can see, the ability to register storage devices as pluggable drivers opens up a wide range of possible devices that you can manage with PowerVC. If you have any questions, post them below. And donâ€™t forget to follow us on LinkedIn, Twitter, and Facebook!
Author: Jagdish Choudhary