The cinder.brick.initiator.connector Module

class AoEConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

Connector class to attach/detach AoE volumes.

connect_volume(*args, **kwargs)

Discover and attach the volume.

connection_properties for AoE must include: target_shelf - shelf id of volume target_lun - lun id of volume

disconnect_volume(*args, **kwargs)

Detach and flush the volume.

connection_properties for AoE must include: target_shelf - shelf id of volume target_lun - lun id of volume

class FibreChannelConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, use_multipath=False, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

Connector class to attach/detach Fibre Channel volumes.

connect_volume(*args, **kwargs)

Attach the volume to instance_name.

connection_properties for Fibre Channel must include: target_portal - ip and optional port target_iqn - iSCSI Qualified Name target_lun - LUN id of the volume

disconnect_volume(*args, **kwargs)

Detach the volume from instance_name.

connection_properties for Fibre Channel must include: target_wwn - iSCSI Qualified Name target_lun - LUN id of the volume

set_execute(execute)
class FibreChannelConnectorS390X(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, use_multipath=False, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.FibreChannelConnector

Connector class to attach/detach Fibre Channel volumes on S390X arch.

set_execute(execute)
class HuaweiStorHyperConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

“Connector class to attach/detach SDSHypervisor volumes.

attach_mnid_done_code = 50151405
attached_success_code = 0
connect_volume(*args, **kwargs)

Connect to a volume.

disconnect_volume(*args, **kwargs)

Disconnect a volume from the local host.

has_been_attached_code = 50151401
is_volume_connected(volume_name)

Check if volume already connected to host

iscliexist = True
not_mount_node_code = 50155007
vbs_unnormal_code = 50151209
class ISCSIConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, use_multipath=False, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

Connector class to attach/detach iSCSI volumes.

connect_volume(*args, **kwargs)

Attach the volume to instance_name.

connection_properties for iSCSI must include: target_portal(s) - ip and optional port target_iqn(s) - iSCSI Qualified Name target_lun(s) - LUN id of the volume Note that plural keys may be used when use_multipath=True

disconnect_volume(*args, **kwargs)

Detach the volume from instance_name.

connection_properties for iSCSI must include: target_portal(s) - IP and optional port target_iqn(s) - iSCSI Qualified Name target_lun(s) - LUN id of the volume

get_initiator()

Secure helper to read file as root.

set_execute(execute)
class ISERConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, use_multipath=False, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.ISCSIConnector

class InitiatorConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.executor.Executor

check_valid_device(path, run_as_root=True)
connect_volume(connection_properties)

Connect to a volume.

The connection_properties describes the information needed by the specific protocol to use to make the connection.

disconnect_volume(connection_properties, device_info)

Disconnect a volume from the local host.

The connection_properties are the same as from connect_volume. The device_info is returned from connect_volume.

static factory(protocol, root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, use_multipath=False, device_scan_attempts=3, arch='x86_64', *args, **kwargs)

Build a Connector object based upon protocol and architecture.

set_driver(driver)

The driver is used to find used LUNs.

class LocalConnector(root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

“Connector class to attach/detach File System backed volumes.

connect_volume(connection_properties)

Connect to a volume.

connection_properties must include: device_path - path to the volume to be connected

disconnect_volume(connection_properties, device_info)

Disconnect a volume from the local host.

class RemoteFsConnector(mount_type, root_helper, driver=None, execute=<function execute at 0x2b439a4b1758>, device_scan_attempts=3, *args, **kwargs)

Bases: cinder.brick.initiator.connector.InitiatorConnector

Connector class to attach/detach NFS and GlusterFS volumes.

connect_volume(connection_properties)

Ensure that the filesystem containing the volume is mounted.

connection_properties must include: export - remote filesystem device (e.g. ‘172.18.194.100:/var/nfs’) name - file name within the filesystem

connection_properties may optionally include: options - options to pass to mount

disconnect_volume(connection_properties, device_info)

No need to do anything to disconnect a volume in a filesystem.

set_execute(execute)
get_connector_properties(root_helper, my_ip, multipath, enforce_multipath)

Get the connection properties for all protocols.

When the connector wants to use multipath, multipath=True should be specified. If enforce_multipath=True is specified too, an exception is thrown when multipathd is not running. Otherwise, it falls back to multipath=False and only the first path shown up is used. For the compatibility reason, even if multipath=False is specified, some cinder storage drivers may export the target for multipath, which can be found via sendtargets discovery.

Previous topic

The cinder.brick.executor Module

Next topic

The cinder.brick.initiator.host_driver Module

This Page