The cinder.volume.drivers.synology.synology_iscsi Module

The cinder.volume.drivers.synology.synology_iscsi Module

class SynoISCSIDriver(*args, **kwargs)

Bases: cinder.volume.driver.ISCSIDriver

OpenStack Cinder drivers for Synology storage.

Version history:
1.0.0 - Initial driver. Provide Cinder minimum features
CI_WIKI_NAME = 'Synology_DSM_CI'
VERSION = '1.0.0'
check_for_setup_error()
create_cloned_volume(volume, src_vref)

Creates a clone of the specified volume.

create_export(context, volume, connector)

Exports the volume.

Can optionally return a Dictionary of changes to the volume object to be persisted.

create_snapshot(snapshot)

Creates a snapshot.

create_volume(volume)

Creates a logical volume.

create_volume_from_snapshot(volume, snapshot)

Creates a volume from a snapshot.

delete_snapshot(snapshot)

Deletes a snapshot.

delete_volume(volume)

Deletes a logical volume.

do_setup(context)

Any initialization the volume driver does while starting.

ensure_export(context, volume)

Synchronously recreates an export for a volume.

extend_volume(volume, new_size)

Extend an existing volume’s size.

get_volume_stats(refresh=False)

Get volume status.

If ‘refresh’ is True, run update the stats first.

initialize_connection(volume, connector)

Initializes the connection and returns connection info.

The iscsi driver returns a driver_volume_type of ‘iscsi’. The format of the driver data is defined in _get_iscsi_properties. Example return value:

{
    'driver_volume_type': 'iscsi',
    'data': {
        'target_discovered': True,
        'target_iqn': 'iqn.2010-10.org.openstack:volume-00000001',
        'target_portal': '127.0.0.0.1:3260',
        'volume_id': 1,
        'discard': False,
    }
}

If the backend driver supports multiple connections for multipath and for single path with failover, “target_portals”, “target_iqns”, “target_luns” are also populated:

{
    'driver_volume_type': 'iscsi',
    'data': {
        'target_discovered': False,
        'target_iqn': 'iqn.2010-10.org.openstack:volume1',
        'target_iqns': ['iqn.2010-10.org.openstack:volume1',
                        'iqn.2010-10.org.openstack:volume1-2'],
        'target_portal': '10.0.0.1:3260',
        'target_portals': ['10.0.0.1:3260', '10.0.1.1:3260'],
        'target_lun': 1,
        'target_luns': [1, 1],
        'volume_id': 1,
        'discard': False,
    }
}
remove_export(context, volume)

Removes an export for a volume.

terminate_connection(volume, connector, **kwargs)

Disallow connection from connector

Parameters:
  • volume – The volume to be disconnected.
  • connector – A dictionary describing the connection with details about the initiator. Can be None.
update_migrated_volume(ctxt, volume, new_volume, status)

Return model update for migrated volume.

Creative Commons Attribution 3.0 License

Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.