The cinder.volume.drivers.hitachi.hnas_nfs
Module¶
Volume driver for HDS HNAS NFS storage.
-
class
HDSNFSDriver
(*args, **kwargs)¶ Bases:
cinder.volume.drivers.nfs.NfsDriver
Base class for Hitachi NFS driver.
Executes commands relating to Volumes.
Version 1.0.0: Initial driver version Version 2.2.0: Added support to SSH authentication Version 3.0.0: Added pool aware scheduling Version 4.0.0: Added manage/unmanage features
-
create_cloned_volume
(volume, src_vref)¶ Creates a clone of the specified volume.
Parameters: - volume – dictionary volume reference
- src_vref – dictionary src_vref reference
-
create_snapshot
(snapshot)¶ Create a snapshot.
Parameters: snapshot – dictionary snapshot reference
-
create_volume
(volume)¶ Creates a volume.
Parameters: volume – volume reference
-
create_volume_from_snapshot
(volume, snapshot)¶ Creates a volume from a snapshot.
-
delete_snapshot
(snapshot)¶ Deletes a snapshot.
Parameters: snapshot – dictionary snapshot reference
-
do_setup
(context)¶ Perform internal driver setup.
-
extend_volume
(volume, new_size)¶ Extend an existing volume.
Parameters: - volume – dictionary volume reference
- new_size – int size in GB to extend
-
get_pool
(volume)¶
-
get_volume_stats
(refresh=False)¶ Get volume stats.
if ‘refresh’ is True, update the stats first.
-
manage_existing
(volume, existing_vol_ref)¶ 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 an NFS share point and some [/path]/volume; e.g., 10.10.32.1:/openstack/vol_to_manage
or 10.10.32.1:/openstack/some_directory/vol_to_manageParameters: - volume – cinder volume to manage
- existing_vol_ref – driver-specific information used to identify a volume
-
manage_existing_get_size
(volume, existing_vol_ref)¶ Returns the size of volume to be managed by manage_existing.
When calculating the size, round up to the next GB.
Parameters: - volume – cinder volume to manage
- existing_vol_ref – existing volume to take under management
-
unmanage
(volume)¶ Removes the specified volume from Cinder management.
It 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
-
-
factory_bend
(drv_config)¶ Factory over-ride in self-tests.