| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Initiator groups
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
NodeACLGroup allows clients to pretend that LIO supports initiator groups.
It logically groups all NodeACLs with the same tag into a NodeACLGroup.
NodeACLGroup's interface is similar but not identical to NodeACL. NodeACLGroup's
interface just uses WWNs (strings) and MappedLUNGroup, so it should be possible
to use these without any use of NodeACL or MappedLUN.
Significant testing and developmental feedback from Gris Ge <fge@redhat.com>.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit 67eb46d88d3d6ccdcde4e8f7d55c959d49878a5a.
This change was premature. We need to wait to increase this until
upstream implements support for more LUNs.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|/
|
|
|
|
|
| |
Give a little more info so mappedluns for nodeacls within a given TPG are
different.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
Add alias property to MappedLUN, and use it.
Simplify control flow in _get_alias()
Eliminate code in LUN._get_storage_object by using self.alias
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
| |
Mention default file used in save_to_file and restore_from_file docstrings.
I tried to use the value of default_save_file instead of the explicit
filename but string interpolation didn't seem to work for the docstring.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
This will make development using PYTHONPATH easier, since rtslib_fb will
exist in the development tree.
No longer need package_dir in setup.py, remove it.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
We should move off of 'rtslib' because we are incompatible with the
original package using this name. Export as 'rtslib_fb', and add a
warning to switch to importing by the new package name if using the old
import name.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Two rtslib objects can point to the same underlying configfs directory
yet be different Python objects. We should consider these equal. Implement
__eq__().
Also implement __ne__() because Python does not assume this is the inverse
of __eq__().
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Instead of defining for both TPG and NodeACL use, just define once.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
This prevents the effort of generating a full list of storage objects or
targets just to see if 1 or more exists.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
It is better placed in the docstring.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
Do not terminate our exception messages with a period. This follows how
they are used in the Python stdlib.
Also remove some str() conversions where the "%s" in the format string
should already be doing the conversion.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Catch all exceptions, and include their message in err_func.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Various fixes for Debian packaging
|
| |
| |
| |
| | |
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
| |
| |
| |
| | |
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|/
|
|
| |
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|
|
|
|
|
| |
Support defining user-backed storage objects.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
Introduced in 608f1c4. _parse_info no longer lowercases, so _get_status
must.
Fixes #53
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Update utils.py
|
|/
|
| |
Need to add backslash to escape the '-' character in regular expression
|
|
|
|
|
|
|
|
|
| |
To work in python3.
fixes #52
Reported-by: Arthur Lutz
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Shouldn't be necessary.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The storageobjects and "mapping" dict in so_from_path are almost the same,
except for name/path divergences due to alt_dirprefix. Consolidate these
into one list, which works with a few duplicate entries.
Put the new so_mapping dict next to bs_params dict, so the places to touch
for new backstores are a little more centralized.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
If there's an error, then future attempts would report the backstore
already exists, instead of whatever the actual error is.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Since the kernel's d0c8b259f (in 3.9+), setting emulate_write_cache for
block backstores has not done anything -- the kernel now actually uses
the queue's REQ_FLUSH flag.
No longer set this attribute, but keep the parameter for backwards
compatibility.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
See https://bugzilla.redhat.com/show_bug.cgi?id=1082208
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
Closes #50
Reported-by: Chris Fielder <shambler.qc@gmail.com>
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
fix typo
|
|/
|
| |
Fixed a small typo in node's set_parameter().
|
|
|
|
|
|
|
|
|
|
|
|
| |
We don't want to silently hide errors when setting things, but we also
don't want to stop. Since these are both called from setup() functions,
we can just pass an err_func to them and they can call it if there's a
problem, but keep going.
When calling set_attribute for the storageobject, use a custom err_func
that also includes the name and plugin in the message.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Also remove unneeded conversions.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
Give it a path and it figures out what kind of storage object to
instantiate.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
Add a print (to stdout, not stderr) if no config file is found, but try
not to make it too scary, since this is perfectly fine.
Fix typo in comment.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Also, fix whitespace.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Also print the original exception message.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
We can now use to_normalized_wwn, since it no longer checks against
wwn_list.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
possible_wwns is no longer used by any callers.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
For tcm_fc and maybe others, it should be possible to configure a target
for a hw-based WWN before the WWN shows up in the list of WWNs. The kernel
code allows and handles this case.
The only downside is that a user might have a typo in entering a hw wwn by
hand, and experience confusion when it is allowed but things don't work
right. Clients may wish to warn the user if so.
Signed-off-by: Andy Grover <agrover@redhat.com>
|