__init__(self,
name,
dev=None,
wwn=None,
readonly=False,
write_back=False)
(Constructor)
|
|
A BlockIOStorageObject can be instantiated in two ways:
-
Creation mode: If dev is specified, the underlying
configFS object will be created with that parameter. No
BlockIOStorageObject with the same name can pre-exist in the
parent Backstore in that mode.
-
Lookup mode: If dev is not set, then the
BlockIOStorageObject will be bound to the existing configFS object in
the parent Backstore having the specified name. The underlying
configFS object must already exist in that mode, or instantiation
will fail.
- Parameters:
name (string) - The name of the BlockIOStorageObject.
dev (string) - The path to the backend block device to be used.
-
Example: dev="/dev/sda".
-
The only device type that is accepted TYPE_DISK. For
other device types, use pscsi.
wwn (string) - T10 WWN Unit Serial, will generate if None
- Returns:
- A BlockIOStorageObject object.
- Overrides:
node.CFSNode.__init__
|