| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Document target parameters and attributes
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Parameters read from the config file system have the same generic
description that does not provide much information:
> get parameter
MaxBurstLength=262144
---------------------
The MaxBurstLength parameter.
This patch provides a description for parameters and attributes by
adding 'ui_desc_parameters' and 'ui_desc_attributes' class members to
the UITPG, UINodeACL and UIStorageObject classes.
The description is read when the parameter is registered with
define_config_group_param(). It is displayed when the user invokes
`get parameter` or `get attribute`:
> get parameter
MaxBurstLength=262144
---------------------
Maximum SCSI data payload in bytes in a Data-In or a solicited Data-Out iSCSI sequence.
This patch also declares the types of parameters. Thus, targetcli can
more efficiently check the parameters when they are set.
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|/
|
|
|
|
|
|
|
| |
The iSCSI RFC defines boolean values as "Yes" and "No" and the LIO
iSCSI target follows this convention to store boolean iSCSI session
parameters (e.g. ImmediateData=Yes). So it makes sense to have a
dedicated helper to validate them in targetcli.
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|
|
|
|
|
|
|
| |
Expand info messages to mention this pref as well
Fixes #46
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
Also, allow e.g "tpg6" as well as "6" for the tpg tag. This matches what
we do for lun creation.
Fixes #47
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
Use complete_path from ui_backstore.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
| |
Since rtslib-fb and configshell-fb have different APIs from the original
rtslib and configshell, we're trying to move off those package names since
it can cause user confusion. Change our version of targetcli to indicate it
requires the -fb versions.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
If not invoked as root, we can't load modules and UIRoot() will raise an
exception.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Fix configuration tree inconsistency
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Deleting a storage object refreshes the root. This causes the root
to release its references to its children and regenerate them. However if
we are cd'd to a node such as /backstores/ramdisk, then the objects
we are using are the old ones, not the new ones connected to the root node,
and creating a new storage object will update our tree but not root's
since we've become disconnected.
Fix this by no longer refreshing the root -- it should not require
refreshing anyways.
Reported-by: Eric Murphy <emurphy@lessorsinc.com>
Reported-by: Leeman Strout <me@mooluv.com>
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|/
|
|
|
|
| |
Slightly more efficient.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
| |
Do not reference the backstore, access the plugin field off the so
directly. This is a regression introduced with the backstore removal
changes a while back.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Fix issue #42 "targetcli manpage not installed by Debian package"
|
| |
| |
| |
| |
| |
| | |
Fixes #42
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|/
|
|
| |
Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
|
|
|
|
|
|
| |
Add support for defining user-backed storage objects.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
We now create a default 0.0.0.0:3260 portal when creating a target.
Change docs to reflect and explain this behavior.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Add --version and --help support to targetcli
|
|/
|
|
|
|
|
| |
I don't envision targetcli taking a lot of cmdline options, so just
implement by looking at sys.argv[1] instead of using getopt or ArgParse.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
Add message that clarifies we're auto-creating the portal, and also
helps to explain what 0.0.0.0 means.
Also, move TPG creation message before, since portal creation depends on
TPG creation.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
This used to translate to setting emulate_write_cache, but this is no
longer supported by the kernel (a good thing).
targetcli commands are not an API, so we can change this whenever it is
appropriate.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
If argument is not a valid storageobject path (or lun, for nodeacl),
also check to see if it's a file or block device, and attempt to
create a new storage object backed by it, and proceed from there.
Enable path autocompletion to go along with this.
This allows mapping a block device to an existing NodeACL in one command.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
| |
Makes things a little easier.
Update manpage quickstart to no longer require this step.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
| |
It's already set that way by default.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
If run_cmdline raises an exception, return 1 as exit code and print
exception text to stderr.
Keep running shell.run_interactive until shell._exit is set, logging
error messages.
Overriding execute_command in UINode no longer needed, remove.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
This stuff is still a pain to get started using. Add a quickstart section
as a band-aid.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
It is possible to create targets for hardware-based targets using WWNs
that are not in the fabric's WWN list. However, if the user is
creating one of these, print a warning, because if the user doesn't
expect this (e.g. made a typo from an existing hw WWN) then things won't
work and it may not be clear why.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Fix issue #23: use fallocate() to create fileio backstores
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
| |
Python 3.3 provides the fallocate() system call which is better for
allocating disk space than ftruncate(). ftruncate() sets the file size
to the requested size but does not reserve the blocks in the file
system. Unlike ftruncate(), fallocate() fails if there is not enough
free space.
Moreover, this patch improves error handling when the file cannot be
opened or when the requested size is too large to be converted to a
long int.
Signed-off-by: Christophe Vu-Brugier <cvubrugier@yahoo.fr>
|
|\
| |
| | |
Add path completion to block and fileio backstores
|
|/
|
|
| |
Signed-off-by: Christophe Vu-Brugier <cvubrugier@yahoo.fr>
|
|
|
|
|
|
|
|
|
| |
As a result it's now better for saveconfig to save/cull backups before
saving the current state, hopefully not a big deal.
Resolves #34
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
|
|
|
| |
Get the RTSRoot object on init, and then use it when needed in other
methods.
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
debian: remove rc script
|
|/
|
|
|
|
| |
This is now in python3-rtslib-fb.
Signed-off-by: Johannes Dewender <github@JonnyJD.net>
|
|
|
|
| |
Signed-off-by: Andy Grover <agrover@redhat.com>
|
|\
| |
| | |
Problem with detecting Python3 on Debian
|
|/
|
|
|
|
| |
python3:any only works in very recent Debian systems (unstable)
Signed-off-by: Johannes Dewender <github@JonnyJD.net>
|
|\
| |
| | |
update debian packaging
|
| |
| |
| |
| | |
Signed-off-by: Johannes Dewender <github@JonnyJD.net>
|
| |
| |
| |
| | |
Signed-off-by: Johannes Dewender <github@JonnyJD.net>
|