Huawei volume driver can be used to provide functions such as the logical volume and snapshot for virtual machines (VMs) in the OpenStack Block Storage driver that supports iSCSI and Fibre Channel protocols.
The following table describes the version mappings among the Block Storage driver, Huawei storage system and OpenStack:
Description (Volume Driver Version) | Storage System Version | Volume Driver Version |
---|---|---|
Create, delete, expand, attach, detach, manage, and unmanage volumes. Create, delete, manage and unmanage a snapshot. Copy an image to a volume Copy a volume to an image Create a volume from a snapshot Clone a volume QoS |
OceanStor T series V1R5 C02/C30 OceanStor T series V2R2 C00/C20/C30 OceanStor V3 V3R1C10/C20 V3R2C10 V3R3C00 OceanStor 2200V3 V300R005C00 OceanStor 2600V3 V300R005C00 OceanStor 18500/18800 V1R1C00/C20/C30 V3R3C00 |
1.1.0 1.1.1 |
Volume Migration(version 1.1.1 or later) Auto zoning(version 1.1.1 or later) SmartTier(version 1.1.1 or later) SmartCache(version 1.1.1 or later) Smart Thin/Thick(version 1.1.1 or later) Replication V2.1(version 1.1.1 or later) |
OceanStor T series V2R2 C00/C20/C30 OceanStor V3 V3R1C10/C20 V3R2C10 V3R3C00 OceanStor 2200V3 V300R005C00 OceanStor 2600V3 V300R005C00 OceanStor 18500/18800V1R1C00/C20/C30 |
1.1.1 |
SmartPartition(version 1.1.1 or later) | OceanStor T series V2R2 C00/C20/C30 OceanStor V3 V3R1C10/C20 V3R2C10 V3R3C00 OceanStor 2600V3 V300R005C00 OceanStor 18500/18800V1R1C00/C20/C30 |
1.1.1 |
This section describes how to configure the Huawei volume driver for either iSCSI storage or Fibre Channel storage.
Pre-requisites
When creating a volume from image, install the multipath tool and add the following configuration keys in the [DEFAULT] configuration group of the /etc/cinder/cinder.conf file:
use_multipath_for_image_xfer = True
enforce_multipath_for_image_xfer = True
To configure the volume driver, follow the steps below:
In /etc/cinder, create a Huawei-customized driver configuration file. The file format is XML.
Change the name of the driver configuration file based on the site requirements, for example, cinder_huawei_conf.xml.
Configure parameters in the driver configuration file.
Each product has its own value for the Product parameter under the Storage xml block. The full xml file with the appropriate Product parameter is as below:
<?xml version="1.0" encoding="UTF-8"?>
<config>
<Storage>
<Product>PRODUCT</Product>
<Protocol>PROTOCOL</Protocol>
<UserName>xxxxxxxx</UserName>
<UserPassword>xxxxxxxx</UserPassword>
<RestURL>https://x.x.x.x:8088/deviceManager/rest/</RestURL>
</Storage>
<LUN>
<LUNType>xxx</LUNType>
<WriteType>xxx</WriteType>
<Prefetch Type="xxx" Value="xxx" />
<StoragePool>xxx</StoragePool>
</LUN>
<iSCSI>
<DefaultTargetIP>x.x.x.x</DefaultTargetIP>
<Initiator Name="xxxxxxxx" TargetIP="x.x.x.x"/>
</iSCSI>
<Host OSType="Linux" HostIP="x.x.x.x, x.x.x.x"/>
</config>
The corresponding ``Product`` values for each product are as below:
For T series V2
<Product>TV2</Product>
For V3
<Product>V3</Product>
For OceanStor 18000 series
<Product>18000</Product>
The Protocol value to be used is iSCSI for iSCSI and FC for Fibre Channel as shown below:
# For iSCSI
<Protocol>iSCSI</Protocol>
# For Fibre channel
<Protocol>FC</Protocol>
Note
For details about the parameters in the configuration file, see the Configuration file parameters section.
Configure the cinder.conf file.
In the [default] block of /etc/cinder/cinder.conf, enable the VOLUME_BACKEND:
enabled_backends = VOLUME_BACKEND
Add a new block [VOLUME_BACKEND], and add the following contents:
[VOLUME_BACKEND]
volume_driver = VOLUME_DRIVER
cinder_huawei_conf_file = /etc/cinder/cinder_huawei_conf.xml
volume_backend_name = Huawei_Storage
Add information about remote devices in /etc/cinder/cinder.conf in target back-end block for Replication.
[VOLUME_BACKEND]
volume_driver = VOLUME_DRIVER
cinder_huawei_conf_file = /etc/cinder/cinder_huawei_conf.xml
volume_backend_name = Huawei_Storage
replication_device =
backend_id: xxx,
storage_pool :xxx,
san_address: https://x.x.x.x:8088/deviceManager/rest/,
san_user: xxx,
san_passowrd: xxx,
iscsi_default_target_ip: x.x.x.x
Note
By default, the value for Replication is None. For details about the parameters in the configuration file, see the Configuration file parameters section.
The volume-driver value for every product is as below:
# For iSCSI
volume_driver = cinder.volume.drivers.huawei.huawei_driver.HuaweiISCSIDriver
# For FC
volume_driver = cinder.volume.drivers.huawei.huawei_driver.HuaweiFCDriver
Run the service cinder-volume restart command to restart the Block Storage service.
To configure iSCSI multipathing, follow the steps below:
Create a port group on the storage device using the DeviceManager and add service links that require multipathing into the port group.
Add the port group settings in the Huawei-customized driver configuration file and configure the port group name needed by an initiator.
<iSCSI>
<DefaultTargetIP>x.x.x.x</DefaultTargetIP>
<Initiator Name="xxxxxx" TargetPortGroup="xxxx" />
</iSCSI>
Enable the multipathing switch of the Compute service module.
If the version of OpenStack is Havana or IceHouse, add libvirt_iscsi_use_multipath = True in [default] of /etc/nova/nova.conf.
If the version of OpenStack is Juno, Kilo, Liberty or Mitaka, add iscsi_use_multipath = True in [libvirt] of /etc/nova/nova.conf.
Run the service nova-compute restart command to restart the nova-compute service.
To configure FC Multipathing, follow the steps below:
Enable the multipathing switch of the Compute service module.
Add iscsi_use_multipath = True in [libvirt] of /etc/nova/nova.conf.
Run the service nova-compute restart command to restart the nova-compute service.
On a public network, any application server whose IP address resides on the same network segment as that of the storage systems iSCSI host port can access the storage system and perform read and write operations in it. This poses risks to the data security of the storage system. To ensure the storage systems access security, you can configure CHAP authentication to control application servers access to the storage system.
Adjust the driver configuration file as follows:
<Initiator ALUA="xxx" CHAPinfo="xxx" Name="xxx" TargetIP="x.x.x.x"/>
ALUA indicates a multipathing mode. 0 indicates that ALUA is disabled. 1 indicates that ALUA is enabled. CHAPinfo indicates the user name and password authenticated by CHAP. The format is mmuser; mm-user@storage. The user name and password are separated by semicolons (;).
Multiple storage systems configuration example:
enabled_backends = v3_fc, 18000_fc
[v3_fc]
volume_driver = cinder.volume.drivers.huawei.huawei_driver.HuaweiFCDriver
cinder_huawei_conf_file = /etc/cinder/cinder_huawei_conf_v3_fc.xml
volume_backend_name = huawei_v3_fc
[18000_fc]
volume_driver = cinder.volume.drivers.huawei.huawei_driver.HuaweiFCDriver
cinder_huawei_conf_file = /etc/cinder/cinder_huawei_conf_18000_fc.xml
volume_backend_name = huawei_18000_fc
This section describes mandatory and optional configuration file parameters of the Huawei volume driver.
Parameter | Default value | Description | Applicable to |
---|---|---|---|
Product | - | Type of a storage product. Possible values are TV2, 18000 and V3. | All |
Protocol | - | Type of a connection protocol. The possible value is either 'iSCSI' or 'FC'. | All |
RestURL | - | Access address of the REST interface, https://x.x.x.x/devicemanager/rest/. The value x.x.x.x indicates the management IP address. OceanStor 18000 uses the preceding setting, and V2 and V3 requires you to add port number 8088, for example, https://x.x.x.x:8088/deviceManager/rest/. If you need to configure multiple RestURL, separate them by semicolons (;). | All |
UserName | - | User name of a storage administrator. | All |
UserPassword | - | Password of a storage administrator. | All |
StoragePool | - | Name of a storage pool to be used. If you need to configure multiple storage pools, separate them by semicolons (;). | All |
Note
The value of StoragePool cannot contain Chinese characters.
Parameter | Default value | Description | Applicable to |
---|---|---|---|
LUNType | Thick | Type of the LUNs to be created. The value can be Thick or Thin. | All |
WriteType | 1 | Cache write type, possible values are: 1 (write back), 2 (write through), and 3 (mandatory write back). | All |
Prefetch Type | 3 | Cache prefetch policy, possible values are: 0 (no prefetch), 1 (fixed prefetch), 2 (variable prefetch), or 3 (intelligent prefetch). | All |
Prefetch Value | 0 | Cache prefetch value. | All |
LUNcopyWaitInterval | 5 | After LUN copy is enabled, the plug-in frequently queries the copy progress. You can set a value to specify the query interval. | All |
Timeout | 432000 | Timeout interval for waiting LUN copy of a storage device to complete. The unit is second. | All |
Initiator Name | - | Name of a compute node initiator. | All |
Initiator TargetIP | - | IP address of the iSCSI port provided for compute nodes. | All |
Initiator TargetPortGroup | - | IP address of the iSCSI target port that is provided for compute nodes. | All |
DefaultTargetIP | - | Default IP address of the iSCSI target port that is provided for compute nodes. | All |
OSType | Linux | Operating system of the Nova compute node’s host. | All |
HostIP | - | IP address of the Nova compute node’s host. | All |
backend_id | - | Target device ID. | All |
storage_pool | - | Pool name of target back-end when failover for replication. | All |
san_address | - | Access address of the REST interface, https://x.x.x.x/devicemanager/rest/. The value x.x.x.x indicates the management IP address. | All |
san_user | - | User name of a storage administrator of replication remote device. | All |
san_password | - | Password of a storage administrator of replication remote device. | All |
iscsi_default_target_ip | - | Remote transacton port IP. | All |
Important
The Initiator Name, Initiator TargetIP, and Initiator TargetPortGroup are ISCSI parameters and therefore not applicable to FC.
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.