This Block Storage volume driver provides iSCSI and NFS support for HNAS (Hitachi Network-attached Storage) arrays such as, HNAS 3000 and 4000 family.
Use the HDS ssc command to
communicate with an HNAS array. This utility package is available in the
physical media distributed with the hardware or it can be copied from
the SMU (/usr/local/bin/ssc
).
Platform: Ubuntu 12.04 LTS or newer.
The base NFS driver combined with the HNAS driver extensions support these operations:
Create, delete, attach, and detach volumes.
Create, list, and delete volume snapshots.
Create a volume from a snapshot.
Copy an image to a volume.
Copy a volume to an image.
Clone a volume.
Extend a volume.
Get volume statistics.
The HDS driver supports the concept of differentiated services (also referred to as quality of service) by mapping volume types to services provided through HNAS. HNAS supports a variety of storage options and file system capabilities which are selected through volume typing and the use of multiple back-ends. The HDS driver maps up to 4 volume types into separate exports/filesystems, and can support any number using multiple back-ends.
Configuration is read from an XML-formatted file (one per backend). Examples are shown for single and multi back-end cases.
Note | |
---|---|
|
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
hds_hnas_iscsi_config_file = /opt/hds/hnas/cinder_iscsi_conf.xml | (StrOpt) Configuration file for HDS iSCSI cinder plugin |
hds_hnas_nfs_config_file = /opt/hds/hnas/cinder_nfs_conf.xml | (StrOpt) Configuration file for HDS NFS cinder plugin |
Before using iSCSI and NFS services, use the HNAS Web Interface to create storage pool(s), filesystem(s), and assign an EVS. For NFS, NFS exports should be created. For iSCSI, a SCSI Domain needs to be set.
In a single back-end deployment, only one OpenStack Block Storage instance runs on the OpenStack Block Storage server and controls one HNAS array: this deployment requires these configuration files:
Set the
hds_hnas_iscsi_config_file
option in the/etc/cinder/cinder.conf
file to use the HNAS iSCSI volume driver. Orhds_hnas_nfs_config_file
to use HNAS NFS driver. This option points to a configuration file.[1]For HNAS iSCSI driver:
volume_driver = cinder.volume.drivers.hds.iscsi.HDSISCSIDriver hds_hnas_iscsi_config_file = /opt/hds/hnas/cinder_iscsi_conf.xml
For HNAS NFS driver:
volume_driver = cinder.volume.drivers.hds.nfs.HDSNFSDriver hds_hnas_nfs_config_file = /opt/hds/hnas/cinder_nfs_conf.xml
For HNAS iSCSI, configure
hds_hnas_iscsi_config_file
at the location specified previously. For example,/opt/hds/hnas/cinder_iscsi_conf.xml
:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.16</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <chap_enabled>True</chap_enabled> <username>supervisor</username> <password>supervisor</password> <svc_0> <volume_type>default</volume_type> <iscsi_ip>172.17.39.132</iscsi_ip> <hdp>fs-01</hdp> </svc_0> </config>
For HNAS NFS, configure
hds_hnas_nfs_config_file
at the location specified previously. For example,/opt/hds/hnas/cinder_nfs_conf.xml
:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.16</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <username>supervisor</username> <password>supervisor</password> <chap_enabled>False</chap_enabled> <svc_0> <volume_type>default</volume_type> <hdp>172.17.44.100:/virtual-01</hdp> </svc_0> </config>
Up to 4 service stanzas can be included in the XML file; named
svc_0
, svc_1
,
svc_2
and svc_3
.
Additional services can be enabled using multi-backend
as described below.
In a multi back-end deployment, more than one OpenStack Block Storage instance runs on the same server. In this example, two HNAS arrays are used, possibly providing different storage performance:
For HNAS iSCSI, configure
/etc/cinder/cinder.conf
: thehnas1
andhnas2
configuration blocks are created. Set thehds_hnas_iscsi_config_file
option to point to an unique configuration file for each block. Set thevolume_driver
option for each back-end tocinder.volume.drivers.hds.iscsi.HDSISCSIDriver
.enabled_backends=hnas1,hnas2 [hnas1] volume_driver = cinder.volume.drivers.hds.iscsi.HDSISCSIDriver hds_hnas_iscsi_config_file = /opt/hds/hnas/cinder_iscsi1_conf.xml volume_backend_name=hnas-1 [hnas2] volume_driver = cinder.volume.drivers.hds.iscsi.HDSISCSIDriver hds_hnas_iscsi_config_file = /opt/hds/hnas/cinder_iscsi2_conf.xml volume_backend_name=hnas-2
Configure the
/opt/hds/hnas/cinder_iscsi1_conf.xml
file:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.16</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <chap_enabled>True</chap_enabled> <username>supervisor</username> <password>supervisor</password> <svc_0> <volume_type>regular</volume_type> <iscsi_ip>172.17.39.132</iscsi_ip> <hdp>fs-01</hdp> </svc_0> </config>
Configure the
/opt/hds/hnas/cinder_iscsi2_conf.xml
file:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.20</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <chap_enabled>True</chap_enabled> <username>supervisor</username> <password>supervisor</password> <svc_0> <volume_type>platinum</volume_type> <iscsi_ip>172.17.30.130</iscsi_ip> <hdp>fs-02</hdp> </svc_0> </config>
For NFS, configure
/etc/cinder/cinder.conf
: thehnas1
andhnas2
configuration blocks are created. Set thehds_hnas_nfs_config_file
option to point to an unique configuration file for each block. Set thevolume_driver
option for each back-end tocinder.volume.drivers.hds.nfs.HDSNFSDriver
.enabled_backends=hnas1,hnas2 [hnas1] volume_driver = cinder.volume.drivers.hds.nfs.HDSNFSDriver hds_hnas_nfs_config_file = /opt/hds/hnas/cinder_nfs1_conf.xml volume_backend_name=hnas-1 [hnas2] volume_driver = cinder.volume.drivers.hds.nfs.HDSNFSDriver hds_hnas_nfs_config_file = /opt/hds/hnas/cinder_nfs2_conf.xml volume_backend_name=hnas-2
Configure the
/opt/hds/hnas/cinder_nfs1_conf.xml
file:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.16</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <username>supervisor</username> <password>supervisor</password> <chap_enabled>False</chap_enabled> <svc_0> <volume_type>regular</volume_type> <hdp>172.17.44.100:/virtual-01</hdp> </svc_0> </config>
Configure the
/opt/hds/hnas/cinder_nfs2_conf.xml
file:<?xml version="1.0" encoding="UTF-8" ?> <config> <mgmt_ip0>172.17.44.20</mgmt_ip0> <hnas_cmd>ssc</hnas_cmd> <username>supervisor</username> <password>supervisor</password> <chap_enabled>False</chap_enabled> <svc_0> <volume_type>platinum</volume_type> <hdp>172.17.44.100:/virtual-02</hdp> </svc_0> </config>
If you use volume types, you must configure them in
the configuration file and set the
volume_backend_name
option to the
appropriate back-end. In the previous multi back-end
example, the platinum
volume type
is served by hnas-2, and the regular
volume type is served by hnas-1.
cinder type-key regular set volume_backend_name=hnas-1 cinder type-key platinum set volume_backend_name=hnas-2
You can deploy multiple OpenStack HNAS drivers instances that each
control a separate HNAS array. Each instance does not need to have a
volume type associated with it. The OpenStack Block Storage filtering
algorithm selects the HNAS array with the largest
available free space. In each configuration file, you
must define the default
volume type in the service labels.
These details apply to the XML format configuration file
that is read by HDS volume driver. These differentiated
service labels are predefined: svc_0
,
svc_1
, svc_2
and svc_3
[2]. Each respective service label associates with
these parameters and tags:
- volume_type
A create_volume call with a certain volume type shall be matched up with this tag. The value
default
is special in that any service associated with this type is used to create volume when no other labels match. Other labels are case sensitive and should exactly match. If no configured volume types match the incoming requested type, an error occurs in volume creation.- hdp
(iSCSI only) Virtual filesystem label associated with the service.
(NFS only) Path to the volume
<ip_address>:/<path>
associated with the service. Additionally, this entry must be added in the file used to list available NFS shares. This file is located, by default, in/etc/cinder/nfs_shares
or you can specify the location in thenfs_shares_config
option in the cinder configuration file.- iscsi_ip
(iSCSI only) An iSCSI IP address dedicated to the service.
Typically a OpenStack Block Storage volume instance has only one such
service label. For example, any svc_0
,
svc_1
, svc_2
or
svc_3
can be associated with it.
But any mix of these service labels can be used in the
same instance [3].
Option | Type | Default | Description |
|
Required |
Management Port 0 IP address. Should be the IP address of the 'Admin' EVS. |
|
|
Optional |
ssc |
|
|
Optional |
True |
(iSCSI only) |
|
Required |
supervisor |
Username is always required on HNAS. |
|
Required |
supervisor |
Password is always required on HNAS. |
|
Optional |
(at least one label has to be defined) |
Service labels: these four predefined names help four different sets of configuration options. Each can specify HDP and a unique volume type. |
|
Required |
|
volume_type tag is used
to match volume type.
|
|
Required |
(iSCSI only) iSCSI IP address where volume attaches for this volume type. |
|
|
Required |
HDP, for HNAS iSCSI is the virtual filesystem label or the path (for HNAS NFS) where volume, or snapshot should be created. |