The cinder.volume.drivers.hitachi.hnas_iscsi Module

iSCSI Cinder Volume driver for Hitachi Unified Storage (HUS-HNAS) platform.

class HNASISCSIDriver(*args, **kwargs)

Bases: cinder.volume.driver.ISCSIDriver

HNAS iSCSI volume driver.

Version history:

code-block:: none

Version 1.0.0: Initial driver version Version 2.2.0: Added support to SSH authentication Version 3.2.0: Added pool aware scheduling

Fixed concurrency errors

Version 3.3.0: Fixed iSCSI target limitation error Version 4.0.0: Added manage/unmanage features Version 4.1.0: Fixed XML parser checks on blank options Version 4.2.0: Fixed SSH and cluster_admin_ip0 verification Version 4.3.0: Fixed attachment with os-brick 1.0.0 Version 5.0.0: Code cleaning up

New communication interface between the driver and HNAS Removed the option to use local SSC (ssh_enabled=False) Updated to use versioned objects Changed the class name to HNASISCSIDriver Deprecated XML config file Fixed driver stats reporting
CI_WIKI_NAME = 'Hitachi_HNAS_CI'
VERSION = '5.0.0'
check_for_setup_error()
create_cloned_volume(*args, **kwargs)

Creates a clone of a volume.

Parameters:
  • dst – dictionary destination volume reference
  • src – dictionary source volume reference
Returns:

the provider location of the extended volume

create_export(context, volume, connector)
create_snapshot(*args, **kwargs)

Creates a snapshot.

Parameters:snapshot – dictionary snapshot reference
Returns:the provider location of the snapshot
create_volume(*args, **kwargs)

Creates a LU on HNAS.

Parameters:volume – dictionary volume reference
Returns:the volume provider location
create_volume_from_snapshot(*args, **kwargs)

Creates a volume from a snapshot.

Parameters:
  • volume – dictionary volume reference
  • snapshot – dictionary snapshot reference
Returns:

the provider location of the snapshot

delete_snapshot(*args, **kwargs)

Deletes a snapshot.

Parameters:snapshot – dictionary snapshot reference
delete_volume(*args, **kwargs)

Deletes the volume on HNAS.

Parameters:volume – dictionary volume reference
do_setup(context)

Sets up and verify Hitachi HNAS storage connection.

ensure_export(context, volume)
extend_volume(*args, **kwargs)

Extends an existing volume.

Parameters:
  • volume – dictionary volume reference
  • new_size – int size in GB to extend
get_volume_stats(refresh=False)

Gets the volume driver stats.

Parameters:refresh – if refresh is True, the driver_stats is updated
Returns:the driver stats
initialize_connection(*args, **kwargs)

Maps the created volume to connector[‘initiator’].

Parameters:
  • volume – dictionary volume reference
  • connector – dictionary connector reference
Returns:

The connection information

Raises:

ISCSITargetAttachFailed

manage_existing(*args, **kwargs)

Manages an existing volume.

The specified Cinder volume is to be taken into Cinder management. The driver will verify its existence and then rename it to the new Cinder volume name. It is expected that the existing volume reference is a File System and some volume_name; e.g., openstack/vol_to_manage

Parameters:
  • volume – cinder volume to manage
  • existing_vol_ref – driver specific information used to identify a volume
Returns:

the provider location of the volume managed

manage_existing_get_size(*args, **kwargs)

Gets the size to manage_existing.

Returns the size of volume to be managed by manage_existing.

Parameters:
  • volume – cinder volume to manage
  • existing_vol_ref – existing volume to take under management
Returns:

the size of the volume to be managed or raises error

Raises:

ManageExistingInvalidReference

remove_export(context, volume)
terminate_connection(*args, **kwargs)

Terminate a connection to a volume.

Parameters:
  • volume – dictionary volume reference
  • connector – dictionary connector reference
unmanage(*args, **kwargs)

Unmanages a volume from cinder.

Removes the specified volume from Cinder management. Does not delete the underlying backend storage object. A log entry will be made to notify the admin that the volume is no longer being managed.

Parameters:volume – cinder volume to unmanage

Previous topic

The cinder.volume.drivers.hitachi.hnas_backend Module

Next topic

The cinder.volume.drivers.hitachi.hnas_nfs Module

This Page