Atom feed of this document
  
Juno -  Juno -  Juno -  Juno -  Juno -  Juno -  Juno -  Juno - 

 HDS HNAS iSCSI and NFS driver

This Block Storage volume driver provides iSCSI and NFS support for HNAS (Hitachi Network-attached Storage) arrays such as, HNAS 3000 and 4000 family.

 System requirements

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.

 Supported operations

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.

 Configuration

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]Note
  • Configuration is read from an XML file. This example shows the configuration for single back-end and for multi-back-end cases.

  • The default volume type needs to be set in configuration file. If there is no default volume type, only matching volume types will work.

Table 1.5. Description of HDS HNAS iSCSI and NFS driver configuration options
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

 HNAS setup

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.

 Single back-end

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:

  1. Set the hds_hnas_iscsi_config_file option in the /etc/cinder/cinder.conf file to use the HNAS iSCSI volume driver. Or hds_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
  2. 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.

 Multi back-end

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:

  1. For HNAS iSCSI, configure /etc/cinder/cinder.conf: the hnas1 and hnas2 configuration blocks are created. Set the hds_hnas_iscsi_config_file option to point to an unique configuration file for each block. Set the volume_driver option for each back-end to cinder.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
  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>
  3. 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>
  1. For NFS, configure /etc/cinder/cinder.conf: the hnas1 and hnas2 configuration blocks are created. Set the hds_hnas_nfs_config_file option to point to an unique configuration file for each block. Set the volume_driver option for each back-end to cinder.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
  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>
  3. 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>
 Type extra specs: volume_backend and volume type

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
 Non-differentiated deployment of HNAS arrays

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.

 HDS HNAS volume driver configuration options

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 the nfs_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].

Table 1.6. Configuration options
Option Type Default Description

mgmt_ip0

Required

Management Port 0 IP address. Should be the IP address of the 'Admin' EVS.

hnas_cmd

Optional

ssc

hnas_cmd is a command to communicate to HNAS array.

chap_enabled

Optional

True

(iSCSI only) chap_enabled is a boolean tag used to enable CHAP authentication protocol.

username

Required

supervisor

Username is always required on HNAS.

password

Required

supervisor

Password is always required on HNAS.

svc_0, svc_1, svc_2, svc_3

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.

volume_type

Required

default

volume_type tag is used to match volume type. default meets any type of volume type, or if it is not specified. Any other volume type is selected if exactly matched during volume creation.

iscsi_ip

Required

(iSCSI only) iSCSI IP address where volume attaches for this volume type.

hdp

Required

HDP, for HNAS iSCSI is the virtual filesystem label or the path (for HNAS NFS) where volume, or snapshot should be created.



[1] The configuration file location may differ.

[2] There is no relative precedence or weight among these four labels.

[3] The get_volume_stats() function always provides the available capacity based on the combined sum of all the HDPs that are used in these services labels.

Questions? Discuss on ask.openstack.org
Found an error? Report a bug against this page

loading table of contents...