Package rtslib :: Module fabric :: Class _BaseFabricModule
[hide private]
[frames] | no frames]

Class _BaseFabricModule

source code

  object --+    
           |    
node.CFSNode --+
               |
              _BaseFabricModule
Known Subclasses:

Abstract Base clase for Fabric Modules. It can load modules, provide information about them and handle the configfs housekeeping. After instantiation, whether or not the fabric module is loaded depends on if a method requiring it (i.e. accessing configfs) is used. This helps limit loaded kernel modules to just the fabrics in use.

Instance Methods [hide private]
 
__init__(self, name)
Instantiate a FabricModule object, according to the provided name.
source code
 
_check_self(self) source code
 
has_feature(self, feature) source code
 
_list_targets(self) source code
 
_get_version(self) source code
 
to_normalized_wwn(self, wwn)
Checks whether or not the provided WWN is valid for this fabric module according to the spec, and returns a tuple of our preferred string representation of the wwn, and what type it turned out to be.
source code
 
to_fabric_wwn(self, wwn)
Some fabrics need WWNs in a format different than rtslib's internal format.
source code
 
from_fabric_wwn(self, wwn)
Converts from WWN format used in this fabric's LIO configfs to canonical format.
source code
 
needs_wwn(self)
This fabric requires wwn to be specified when creating a target, it cannot be autogenerated.
source code
 
_assert_feature(self, feature) source code
 
clear_discovery_auth_settings(self) source code
 
_get_discovery_enable_auth(self) source code
 
_set_discovery_enable_auth(self, enable) source code
 
_get_discovery_authenticate_target(self) source code
 
_get_wwns(self)
Returns either iterable or None.
source code
 
_get_disc_attr(self, *args, **kwargs) source code
 
_set_disc_attr(self, *args, **kwargs) source code
 
setup(self, fm, err_func)
Setup fabricmodule with settings from fm dict.
source code
 
dump(self) source code

Inherited from node.CFSNode: delete, get_attribute, get_parameter, list_attributes, list_parameters, set_attribute, set_parameter

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]

Inherited from node.CFSNode: configfs_dir

Properties [hide private]
  discovery_enable_auth
Set or get the discovery enable_auth flag.
  discovery_authenticate_target
Get the boolean discovery authenticate target flag.
  discovery_userid
Set or get the initiator discovery userid.
  discovery_password
Set or get the initiator discovery password.
  discovery_mutual_userid
Set or get the mutual discovery userid.
  discovery_mutual_password
Set or get the mutual discovery password.
  targets
Get the list of target objects.
  version
Get the fabric module version string.
  wwns
iterable of WWNs present for this fabric

Inherited from node.CFSNode: exists, path

Inherited from object: __class__

Method Details [hide private]

__init__(self, name)
(Constructor)

source code 

Instantiate a FabricModule object, according to the provided name.

Parameters:
  • name (str) - the name of the FabricModule object. It must match an existing target fabric module specfile (name.spec).
Overrides: object.__init__

_check_self(self)

source code 
Overrides: node.CFSNode._check_self

to_fabric_wwn(self, wwn)

source code 

Some fabrics need WWNs in a format different than rtslib's internal format. These fabrics should override this method.

from_fabric_wwn(self, wwn)

source code 

Converts from WWN format used in this fabric's LIO configfs to canonical format. Note: Do not call from wwns(). There's no guarantee fabric wwn format is the same as wherever wwns() is reading from.

_get_wwns(self)

source code 

Returns either iterable or None. None means fabric allows arbitrary WWNs.

dump(self)

source code 
Overrides: node.CFSNode.dump

Property Details [hide private]

discovery_enable_auth

Set or get the discovery enable_auth flag.

Get Method:
_get_discovery_enable_auth(self)
Set Method:
_set_discovery_enable_auth(self, enable)

discovery_authenticate_target

Get the boolean discovery authenticate target flag.

Get Method:
_get_discovery_authenticate_target(self)

discovery_userid

Set or get the initiator discovery userid.

Get Method:
<functools.partial object at 0x18f68e8>
Set Method:
<functools.partial object at 0x18f6940>

discovery_password

Set or get the initiator discovery password.

Get Method:
<functools.partial object at 0x18f69f0>
Set Method:
<functools.partial object at 0x18f6a48>

discovery_mutual_userid

Set or get the mutual discovery userid.

Get Method:
<functools.partial object at 0x18f6af8>
Set Method:
<functools.partial object at 0x18f6b50>

discovery_mutual_password

Set or get the mutual discovery password.

Get Method:
<functools.partial object at 0x18f6c00>
Set Method:
<functools.partial object at 0x18f6c58>

targets

Get the list of target objects.

Get Method:
_list_targets(self)

version

Get the fabric module version string.

Get Method:
_get_version(self)

wwns

iterable of WWNs present for this fabric

Get Method:
_get_wwns(self) - Returns either iterable or None.