Mike Christie [Tue, 1 Jul 2008 01:14:03 +0000 (30 20:14 -0500)]
Bump version for new release.
Mike Christie [Tue, 1 Jul 2008 01:10:24 +0000 (30 20:10 -0500)]
fix dynamic tpgt support.
Older tools allowed you to not set the tpgt when you created
a record manually. If you update a record, iscsiadm will
update the record format for you if it is supportable. In
this case supportable meant that you had to have a tpgt set.
We checked for it in some other cases, but missed it here for
some reasons. This patch fixes that.
Mike Christie [Sat, 14 Jun 2008 02:28:04 +0000 (13 21:28 -0500)]
remove sysfs_file
We do not need sysfs_file, so remove it.
Mike Christie [Fri, 13 Jun 2008 23:45:28 +0000 (13 18:45 -0500)]
Fix login redirect failure handling.
If the login redirect fails, we currently retry forever.
This was because initiator.c could not figure out how
to best cleanup the mess. But now we do :) so this
patch allows the initiator to either retry the reopen or
fail.
Mike Christie [Fri, 13 Jun 2008 21:43:55 +0000 (13 16:43 -0500)]
fix ipv6 login redirect support.
If the target gives us brackets ([]) in the ipv6 name we need
to drop then when passing the ipv6 addr to the network functions.
The discovery and iscsiadm command line code does this already, but
the login redirect code is not, and this results in the login failing
and iscsiadm hanging.
Mike Christie [Wed, 11 Jun 2008 22:08:25 +0000 (11 17:08 -0500)]
Fix discovery and autobinding
Only autobind to the default iface if no ifaces are passed in.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 21:51:07 +0000 (11 16:51 -0500)]
Fix idbm iscsid segfault when accsing ifaces
If iscsid loops over the sessions then it may access the idbm
db's ifaces, so we need to init the idbm when iscsid starts.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Fri, 13 Jun 2008 21:39:09 +0000 (13 16:39 -0500)]
Fix transport_name compat support.
This lists the default iface stuff as unstable and adds back support
for node.transport_name and iface.transport_name. We will not merge
Doran's patch for now because I just do not have time to deal with
regressions., but I am adding in a hack to make sure we
do not change the transport name while a session is running.
Mike Christie [Wed, 11 Jun 2008 18:45:54 +0000 (11 13:45 -0500)]
libiscsi: support older tools that did not set can_queue/cmds_max
Older tools did not pass the kernel the can_queue/cmds_max, so
if not set then use the old default max.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 18:43:41 +0000 (11 13:43 -0500)]
iscsid: don't print enosys errors.
Do not print ENOSYS errors from netlink.c, because they are probably
harmless. Let the handler decide if they want to log the error.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 15:31:34 +0000 (11 10:31 -0500)]
Update 2.6.24 - 2.6.25 patch
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 15:27:14 +0000 (11 10:27 -0500)]
Update 2.6.20 - 2.6.24 patch
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 15:21:53 +0000 (11 10:21 -0500)]
Update 2.6.14 - 2.6.19 compat patch
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 11 Jun 2008 15:15:25 +0000 (11 10:15 -0500)]
Sync kernel modules to scsi-misc for 2.6.27.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Fri, 6 Jun 2008 23:09:41 +0000 (6 18:09 -0500)]
Increase login retry for iscsistart.
For iscsistart we want to try to login a little longer than normal
because if it does not work, we are screwed. This sets it to 120
which will be over 2 minutes.
Mike Christie [Sun, 1 Jun 2008 04:54:19 +0000 (31 23:54 -0500)]
Only autobind to ifaces with transport = tcp
This just adds back the old behavior as the default where we
would only autobind to ifaces that are using iscsi_tcp for
the transport type.
Autobinding to iser and bnx2i is not working as it is today, because
it is only based on the modules being loaded. It should be based on
if the hardware is properly setup or if the user requested it in
the config or something else.
Mike Christie [Sun, 1 Jun 2008 04:47:12 +0000 (31 23:47 -0500)]
Fix sysfs handling of block:sdX and scsi bus changes
This has us use the udev_sysfs code instead of hacking our own.
There are two items that need future proofing:
1. handling of iscsi_session class device symlinks
2. scanning opens /sys/class/iscsi_* dir instead of doing
a proper search like udev_sysfs.
Mike Christie [Thu, 29 May 2008 22:27:11 +0000 (29 17:27 -0500)]
fix compilation on Fedora 9
We need to inlude limits.h for INT_MAX's definition.
Mike Christie [Fri, 23 May 2008 19:03:52 +0000 (23 14:03 -0500)]
Fix iser create bound session compat
For some dumb reason I did not add compat support for
iser when adding support for missing ISCSI_UEVENT_CREATE_BOUND_SESSION
handlers. This patch checks if we do kernel ep connects. If we do
then we try the ISCSI_UEVENT_CREATE_BOUND_SESSION command. If
that fails or if we do the userspace connect then we do the nonbinding/old
ISCSI_UEVENT_CREATE_SESSION command.
Mike Christie [Tue, 20 May 2008 02:20:44 +0000 (19 21:20 -0500)]
pass ep to session creation
bnx2i allocates a host per session and iser accesses the
device so we need to pass them a the leading connection
so they can find the hardware that is it bound to.
This also has us call ep_disconnect before calling the stop
conn callout, so these driver do not have to worry about
stopping the receiving path.
Mike Christie [Mon, 19 May 2008 23:10:33 +0000 (19 18:10 -0500)]
Revert Release-transport-entry-when-the-transport-is-unload.patch
We do not need a new event to figure out that a transport is missing.
We can just check before accessing the transport.
This reverts the original patch.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Fri, 9 May 2008 00:40:15 +0000 (8 19:40 -0500)]
libiscsi: fix recv tmo
If the ping tmo is longer than the recv tmo then we could miss a recv
tmo check, because the ping code will set the next timeout for the
ping timeout. This patch has the ping processing code kick off a recv
tmo check when getting a nop in response to our ping.
Mike Christie [Tue, 6 May 2008 02:45:13 +0000 (5 21:45 -0500)]
libiscsi: Fix nop timeout handling
If the transport timer wakes at the exact same time we were supposed
to check the transport we drop the connection instead of checking
it.
Mike Christie [Sun, 27 Apr 2008 04:32:06 +0000 (26 23:32 -0500)]
Fix ep_disconnect handling of invalid ep
The ep handle is a unsigned number so we cannot check it for less
than zero like we do for iscsi_tcp's socket fd. Check of -1.
Mike Christie [Sat, 26 Apr 2008 22:20:38 +0000 (26 17:20 -0500)]
Release transport entry when the transport is unloaded
When iscsid detects a new transport (e.g. iscsi_tcp, ib_iser), it
allocates an entry for it in the transport list. If the transport
is unloaded and then reloaded, iscsid would still use the old
transport entry. Therefore, the transport entry must be deleted
when the transport is unloaded.
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Mike Christie [Tue, 22 Apr 2008 23:02:40 +0000 (22 18:02 -0500)]
Support mutlple ifaces with the same binding (lack of binding).
If you wanted to be able to create multiple session to the same
target portal, then you can now do
iscsiadm -m iface -I iface0 -o new
If you want to, set a binding:
iscsiadm -m iface -I iface0 ....set your binding
repeat iface creation
iscsiadm -m discovery -t st -p ip:port -I iface0 -I iface1 -I ....
or you can create and bind statically
iscsiadm -m node -T my_target -i ip:port,tpgt -I iface0 -I iface1 -I ....
then login like normal. Or you can login/logout of specific ifaces
like with the normal binding.
There is one known bug where discovery is not printing the
portals and binding setup nicely.
Mike Christie [Tue, 22 Apr 2008 17:04:13 +0000 (22 12:04 -0500)]
Fix bad merge. User iscsi param masks instead of params.
Fix bad merge. User iscsi param masks instead of params
when checking transport caps.
Mike Christie [Mon, 21 Apr 2008 03:15:32 +0000 (20 22:15 -0500)]
Do not allow iface setting to be changed in node mode.
This temporarily breaks iscsi_discovery and probably other apps
for distros that wanted to set iface.transport_name. In the
patch to add default a iser iface we broke node.transport_name,
so this means there is no backward compat for that setting
and you must use the new default iser iface.
Before this is released we will add some compat code somewhere and
fix up the check in iscsiadm for iface settings based on Dorn's patch.
Mike Christie [Sun, 20 Apr 2008 21:13:42 +0000 (20 16:13 -0500)]
User 64 bit params mask.
ifacename put is going to put us over the limit, so have
the session param mask match the kernel one.
Mike Christie [Sun, 20 Apr 2008 19:38:57 +0000 (20 14:38 -0500)]
fix compile warning for missing iface.h
Mike Christie [Sun, 20 Apr 2008 10:19:49 +0000 (20 05:19 -0500)]
set header digests to off by default
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 10:15:17 +0000 (20 05:15 -0500)]
Use startup definition in util.c.
Use startup definition in util.c
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 10:11:57 +0000 (20 05:11 -0500)]
break up iface code and add default iser, tcp/default and bnx2i ifaces
This patch moves the iface code to iface.c/.h. It also adds some
default ifaces for iser and bnx2i. Currently if those modules
are loaded then we will bind to them along with default/tcp when
discovery is run. The user can then set the startup flag or delete
the record.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 17:56:13 +0000 (20 12:56 -0500)]
Add bind by initiatorname
You can now setup the initiator to use multiple initiatornames
which may come in handy for virtualization.
To setup a iface with inames do:
iscsiadm -m iface -o new -I iname0
iscsiadm -m iface -I iname0 -o update -n iface.initiatorname -v "your new name"
Then you can bind and use the interface like you would before.
QUIRK:
Because you can pass in multiple ifaces to the discovery command we
use the default initiator name in /etc/iscsi/initiatorname.iscsi for
the discovery session.
node.transport_name is no longer supported. In the next patches you
will be able to use the default ifaces for these transports.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 07:53:26 +0000 (20 02:53 -0500)]
rm num_transports from sysfs header.
rm num_transports from sysfs header.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 07:50:57 +0000 (20 02:50 -0500)]
rm db param
There is no need to pass the db to almost every function. Just
allocate it as static in idbm.c.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sun, 20 Apr 2008 19:37:41 +0000 (20 14:37 -0500)]
add ifacename support tools
Set ifacename so we can look it back up on iscsid restart.
Mike Christie [Sun, 20 Apr 2008 17:51:20 +0000 (20 12:51 -0500)]
iscsi class/if kernel: add ifacename attr
This adds a attr that userspace can use to set a id for
the session similar to setting a network inteface's name.
It is used for binding hba and port attrs to a session.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Sat, 19 Apr 2008 09:07:54 +0000 (19 04:07 -0500)]
change mgmt_ipc to logout by sid
Operations on sessions are almost all done by sid. The exception
was logout. This patch modifies logout to use sid instead of record
info which should make matching easier in the future.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Hannes Reinecke [Wed, 9 Apr 2008 06:39:00 +0000 (9 08:39 +0200)]
Update SUSE init scripts
These are some updates to the SUSE init scripts, plus a new
boot.open-iscsi script for SUSE. The latter is used for
root on iscsi, to start iscsid as early as possible to
avoid deadlocks on the root fs.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Mike Christie [Wed, 9 Apr 2008 00:13:10 +0000 (8 19:13 -0500)]
disable iscsi_discovery qla4xxx support
iscsi_discovery is not familiar with qla4xxx and cannot just set
the transport name for it. This patch removes mentions of qla4xxx
in the script.
Doron Shoham [Mon, 7 Apr 2008 11:31:24 +0000 (7 14:31 +0300)]
fix white spaces and blank lines removal
fix white spaces and blank lines removal.
Signed-off-by: Doron Shoham <dorons@voltaire.com>
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Doron Shoham [Mon, 7 Apr 2008 11:30:38 +0000 (7 14:30 +0300)]
check if iscsid is running
check if iscsid is running.
if iscsid is not running exit the script.
Signed-off-by: Doron Shoham <dorons@voltaire.com>
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Mike Christie [Tue, 8 Apr 2008 19:09:06 +0000 (8 14:09 -0500)]
Add additional flags to iscsi_discovery
From Doron:
Add additional flag:
-t set trasnpot (default is tcp).
-f force specific transport -disable the fallback to tcp (default is fallback enabled).
force the transport specified by the argument of the -t flag.
-m manual startup - will set manual startup (default is automatic startup).
-l login - login to the new discovered nodes (defualt is false).
Signed-off-by: Doron Shoham <dorons@voltaire.com>
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Minor teak to get it merged from Mike Christie.
Doron Shoham [Mon, 7 Apr 2008 11:28:51 +0000 (7 14:28 +0300)]
fixed printing debug information
dbg() didn't check correctly whether the dbg is true
or false.
Signed-off-by: Doron Shoham <dorons@voltaire.com>
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Hannes Reinecke [Tue, 8 Apr 2008 14:51:27 +0000 (8 16:51 +0200)]
Fixup IPC leak in iscsid
Hi Mike,
iscsid is leaking IPC identifiers when the startup fails.
Please apply.
Cheers,
Hannes
--
Dr. Hannes Reinecke zSeries & Storage
hare@suse.de +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Markus Rex, HRB 16746 (AG Nürnberg)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To post to this group, send email to open-iscsi@googlegroups.com
To unsubscribe from this group, send email to open-iscsi-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/open-iscsi
-~----------~----~----~----~------~----~------~--~---
Fixup IPC leak in iscsid
If iscsid is terminated due to a failure we're leaking IPC ids.
And we're not clearing the log area, causing iscsid to oops if
invoked twice.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Tue, 8 Apr 2008 14:36:27 +0000 (8 16:36 +0200)]
Clean up error codes for iscsid
Hi Mike,
iscsid is using a mixture of '1' or '-1' to signal a failure.
We should rather use '1' consistently.
Cheers,
Hannes
--
Dr. Hannes Reinecke zSeries & Storage
hare@suse.de +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Markus Rex, HRB 16746 (AG Nürnberg)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To post to this group, send email to open-iscsi@googlegroups.com
To unsubscribe from this group, send email to open-iscsi-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/open-iscsi
-~----------~----~----~----~------~----~------~--~---
Cleanup error codes for iscsid
iscsid should use consistent error codes; we should always
return '1' on failure, not a mixture of '-1' and '1'.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Tue, 8 Apr 2008 14:32:50 +0000 (8 16:32 +0200)]
Use correct debug option '-d' for iscsiadm
Hi Mike,
the debug option for iscsiadm is '-d', not '-g'.
Cheers,
Hannes
--
Dr. Hannes Reinecke zSeries & Storage
hare@suse.de +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Markus Rex, HRB 16746 (AG Nürnberg)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "open-iscsi" group.
To post to this group, send email to open-iscsi@googlegroups.com
To unsubscribe from this group, send email to open-iscsi-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/open-iscsi
-~----------~----~----~----~------~----~------~--~---
>From
c41c5045e6d91e76895d4221d03e4f8ce438032f Mon Sep 17 00:00:00 2001
From: Hannes Reinecke <hare@suse.de>
Date: Fri, 7 Mar 2008 15:58:10 +0100
Subject: [PATCH] Correct debug option for iscsiadm
The debug option is '-d', not '-g'.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Mike Christie [Tue, 8 Apr 2008 02:23:00 +0000 (7 21:23 -0500)]
test pattern netdev instead of iface netdev when matching ifaces
When we match netdevs we should check if the pattern is valid/bound. If it
is not then we do not want to try and match the ifaces netdev. We were testing
the iface's netdev instead and that is going to always be set from the
current callers (sysfs iters and from create_node_rec paths).
Mike Christie [Tue, 8 Apr 2008 00:53:08 +0000 (7 19:53 -0500)]
Do not logout session if the record is going to be deleted.
If a session is using a record we do not want to remove the record
because some commands need to check the node.startup and iface settings.
During devel of this release we added code to logout the session then
delete it, but the problem will be if the user just wanted to delete
the record but was still using the session. In this case the devices
are removed and the user will get FS errors.
For now we will just warn and advise the user, so they can manually
log out. In the next release we can add a force flag to logout.
Mike Christie [Mon, 31 Mar 2008 23:57:12 +0000 (31 18:57 -0500)]
convert iscsi_discovery to use iface settings
node.transport_name was replaced with iface.transport_name because
we needed to bind the interface to the driver for qla4xxx and bnx2i.
This converts iscsi_discovery to use the new value.
Note: there was compat support in iscsiadm for both values, but it
was agreed that because of its limited use and hacks needed to support
compat we would just drop it. This will affect distros that do
not carry iscsi_discovery, becuase the primary discovery tool for iser
was that script.
Mike Christie [Mon, 31 Mar 2008 23:27:25 +0000 (31 18:27 -0500)]
fix handling of fatal login errors
For errors initiator.c determines as fatal we should not continue to
retry the log in.
Mike Christie [Mon, 31 Mar 2008 22:56:14 +0000 (31 17:56 -0500)]
allow discovery to overwrite records if a session is using it
If a node record exists for a session we should allow discovery to
overwrite it because it causes a regression for users of iscsi_tcp.
The only value we cannot change is iface.transport_name
(the primary binding iface values are checked as part of the stale
record end to end checks), and the iface.transport_name is only changed
by iscsi_discovery and that has its own checks for now.
In the next release we are going to fix up the iface values so transport
name is a binding value, but it is too late for that, so we just do not
want to add any regressions.
Mike Christie [Mon, 31 Mar 2008 22:05:34 +0000 (31 17:05 -0500)]
Fix session mode -r operations when non tcp module is used
If a module other than iscsi_tcp is used, session mode's -r argument
does not pick up the transport type correctly.
Mike Christie [Wed, 26 Mar 2008 23:59:43 +0000 (26 18:59 -0500)]
Bump version to 2.0-869
When we do a sync with the kernel we pulled in the new kernel version,
but did not sync the userspace version number.
Mike Christie [Thu, 20 Mar 2008 16:25:28 +0000 (20 11:25 -0500)]
fix mkfs regression test
This starting of the mkfs regression test. To run do
regression.sh -f /dev/sdb
Mike Christie [Thu, 20 Mar 2008 15:43:36 +0000 (20 10:43 -0500)]
Fixup debian info
Patch and info from Andrew Moise:
Okay, patch is attached. I wound up doing some things differently
than I mentioned -- the trouble with KERNEL_TARGET turned out to just
be because I hadn't installed the needed headers, and I added the
dpkg-divert script as a Makefile target instead of a snippet of code
in the docs that people have to cut and paste. I also mentioned the
ib_iser situation (which I hope I described accurately).
Mike Christie [Thu, 20 Mar 2008 15:23:08 +0000 (20 10:23 -0500)]
use scsi host dir define
Use a scsi host dir define.
Mike Christie [Thu, 20 Mar 2008 15:20:15 +0000 (20 10:20 -0500)]
fix printing of ipv4 address in session mode
We normally print out the ipv6 address in brackets, but for
the iface address we were not.
Mike Christie [Sun, 16 Mar 2008 00:04:03 +0000 (15 19:04 -0500)]
2.6.14-19 compat fix ups
Update 2.6.14-19_compat.patch for 2.6.25 sync up.
Mike Christie [Sat, 15 Mar 2008 23:53:40 +0000 (15 18:53 -0500)]
Add 2.6.24 compat support
Add 2.6.24 compat support
Mike Christie [Sat, 15 Mar 2008 23:42:47 +0000 (15 18:42 -0500)]
update 2.6.20-21_compat.patch
update 2.6.20-21_compat.patch for 2.6.25 sync up.
Mike Christie [Sat, 15 Mar 2008 23:26:05 +0000 (15 18:26 -0500)]
Sync up with 2.6.25
Sync up with 2.6.25. This does not contain compat patches.
Mike Christie [Fri, 14 Mar 2008 17:17:40 +0000 (14 12:17 -0500)]
Fix handling of data ending on segment boundaries
It is ok for the data to end right on the boundary, so we do
not want to check for equal to.
Mike Christie [Fri, 14 Mar 2008 17:13:43 +0000 (14 12:13 -0500)]
Use CHAP info from sysfs when restarting iscsid.
If you are starting iscsid with sessions running then you are
probably doing iscsi boot or had to restart due to a iscsid bug.
For iscsi boot, the ibft data is the most up to date so we do
not want to use the node db info. This patch is sort of hacky,
and in the next release we will clean up the iscsi_sysfs code
and export everything we need (the only problem is the the
program run during boot may not set all the values like segment
lengths or timeouts so we may still need this hack).
Mike Christie [Fri, 14 Mar 2008 17:12:13 +0000 (14 12:12 -0500)]
sync up README and iscsi.conf comments about node.startup
Since we do not support MCS, we just want to use the node.startup
setting. We still support node.conn[0].startup for compat reasons.
Mike Christie [Fri, 22 Feb 2008 18:13:25 +0000 (22 12:13 -0600)]
fix printing of session info when sid is passed in.
When I added OP_NOOP I did not convert the session printing
code correctly and so the session's record info was printed
instead of the session info. This patch fixes that and it
merges the session printing code.
Mike Christie [Fri, 22 Feb 2008 17:36:04 +0000 (22 11:36 -0600)]
print iface record info
If you do iscsiadm -m node -T tgt -p ip it will print out the
record info, but there is no equivalent command for iface mode.
This adds iscsiadm -m iface -I iface which will dump the record
info. It currrently spits out the same info as the other commands
because we only have the binding info in there. In the future
it will also display the iface's default node values.
Mike Christie [Thu, 21 Feb 2008 22:10:15 +0000 (21 16:10 -0600)]
Add some info about the scsi command timer in the README
Document how to set the scsi command timer in the README.
Mike Christie [Thu, 21 Feb 2008 21:57:26 +0000 (21 15:57 -0600)]
Bump version to 2.0-868.
This almost syncs us up with 2.6.25. The iscsi patches are in sync,
but some upstream kernel api changes are not in this release (this
is why it does not support 2.6.25 yet).
Mike Christie [Thu, 21 Feb 2008 21:54:56 +0000 (21 15:54 -0600)]
The session age mask is only 4 bits, but session->age is 32. When
it gets larger then 15 and we try to or the bits some bits get
dropped and the check for session age in iscsi_verify_itt is useless.
The ISCSI_CID_MASK related bits are also useless since cid is always
one.
Mike Christie [Thu, 21 Feb 2008 21:44:37 +0000 (21 15:44 -0600)]
Fix connection cleanup when iscsid is restarted.
If iscsid is restarted while a session is running, then the
session is logged out we are leaving the iscsi connection
in the kernel. The reason for this is because conn->ksetup
is not set during the sync up. Instead of that hacky bool
we can just check the kernel if there is a connection setup
by looking in sysfs.
Mike Christie [Thu, 21 Feb 2008 19:34:33 +0000 (21 13:34 -0600)]
Add more checks for invalid record updates.
Some values like target name or ip address should be changed.
This adds some checks in idbm.c for this.
Some values like iface bind info should only be modified in
iface mode. This patch adds some checks to iscsiadm.c for this.
This also adds a log message if we have to log out a session
before deleting its record.
Mike Christie [Wed, 20 Feb 2008 18:59:34 +0000 (20 12:59 -0600)]
uclibc support
Bug report and Patch from From Natanael Copa:
I'm trying to compile open-iscsi on uclibc to be able to use it on
embedded linux.
I found out that there are 3 functions that are used that are not
implemented in uclibc: getifaddrs, freeifaddrs and versionsort. None of
those are in POSIX afaik.
Mike Christie [Wed, 20 Feb 2008 18:55:42 +0000 (20 12:55 -0600)]
Add fwparam bison and flex output files
It looks like a lot of users do not have flex and bison, so to
avoid compilation questions and hassling user when only ppc
needs them include the bison and flex output files.
Mike Christie [Wed, 20 Feb 2008 18:08:22 +0000 (20 12:08 -0600)]
Fix compilation on gcc 4.3
Fix some compilation errors with gcc 4.3.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 20 Feb 2008 17:59:34 +0000 (20 11:59 -0600)]
handle ipv6 mapped and compat addresses in isns code
A couple servers are sending compat and mapped addreses
even though the the isns spec states that we must use mapped.
Until we can fix all those servers (since some are out of
our control), we support both for now.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 30 Jan 2008 00:38:17 +0000 (29 18:38 -0600)]
merge iface record iter functions
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 30 Jan 2008 00:31:22 +0000 (29 18:31 -0600)]
Add options to modify the db manipulation behavior during discovery
Instead of overwriting existing node records, you can modify the
behavior by passing in different ops.
Pass -o new to add new nodes.
Pass -o delete to delete stale ones.
Pass -o update to update the records of existing nodes.
And pass combos of different ops for different behavior.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Mike Christie [Wed, 23 Jan 2008 23:19:14 +0000 (23 17:19 -0600)]
Use new tpgt instead of failing login
If we get a new tpgt during login then we fail the login until the user
manually kills the session. The reason for the mixup can be due to
a reconfig on the target, or during ibft boot where we do not get the
tpgt from ibft info, or because the tools made a mistake. This patch
just has iscsid use the new tpgt assuming it was a reconfig or ibft
boot. In the future we will do whatever discovery was performed to
find the portal, to confirm the change.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Erez Zilber [Wed, 16 Jan 2008 12:19:00 +0000 (16 14:19 +0200)]
Remove confusing echo in iscsi_discovery
When a target is discovered and the initiator was able to connect to it,
it prints "connected to 1". A user may think that the initiator is
currently connected to that target (which is wrong).
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Erez Zilber [Wed, 16 Jan 2008 12:17:39 +0000 (16 14:17 +0200)]
Do not run discovery on portals that open-iscsi is logged-in to
Running a discovery on a portal that open-iscsi is logged in to may result
in changes to a logged-in node (like changing the node's transport type).
Changing these properties shouldn't be done while logged in.
Signed-off-by: Erez Zilber <erezz@voltaire.com>
Mike Christie [Tue, 22 Jan 2008 20:14:46 +0000 (22 14:14 -0600)]
Add iscsiadm -m fw -l command
We can do iscsiadm -m node -l, and this logs into all
the portals in the db. This patch adds the equivalent for
fw mode.
Doron Shoham [Wed, 16 Jan 2008 14:45:58 +0000 (16 16:45 +0200)]
When stopping open iscsi check that all the modules are going down correctly
While stopping open-iscsi, the initd script removes
the modules by running 'modprobe -r'. The retval of
modprobe must be tested.
Signed-off-by: Doron Shoham <dorons@voltaire.com>
Mike Christie [Sun, 30 Dec 2007 09:29:17 +0000 (30 03:29 -0600)]
Fix sendtargets multiple pdu handling
Yet another strings.c fix :)
When enlarging the buffer, we were memsetting too far because
we did not take into account that the buffer could have been
partially full.
Mike Christie [Thu, 20 Dec 2007 19:30:38 +0000 (20 13:30 -0600)]
iscsid: fix log closing on startup errors
During start if we exited we did not close the logging proc.
Mike Christie [Sun, 16 Dec 2007 04:55:42 +0000 (15 22:55 -0600)]
fix iscsid.conf comment about def qdepth
The default device qdepth is 32 and not 128.
Mike Christie [Sat, 15 Dec 2007 05:42:57 +0000 (14 23:42 -0600)]
must set rec burst length with session value
Must set rec burst length with session value when fixing up
the value for the user, or during a reloing we could use
the bad value.
Mike Christie [Sat, 15 Dec 2007 05:28:32 +0000 (14 23:28 -0600)]
fix first_burst vs max_burst printf
Printing out the max_burst when we wanted to print out the first burst.
Mike Christie [Sat, 15 Dec 2007 05:11:52 +0000 (14 23:11 -0600)]
partial revert of burst setting patch
In this commit
2bfae61e36dd981f28b59b026542f145c70c70c8,
we started to only check the burst lengths in userspace
if immediate data is yes or of initial r2t is no. It turns
out that targets like netapp and iqstore will always check this
value and fail the login, so to avoid that mess this patch
always checks the value. You will end up getting a error
message in cases where you should not but at least the login
always succeeds and we will not have to help the user try
to figure out what their target error message means.
Mike Christie [Sat, 15 Dec 2007 02:45:55 +0000 (14 20:45 -0600)]
fix 2.6.14-19 compat patch
Must pass iscsi session to __iscsi_unbind_session because
of the way the old workqueue api passed the data instead
of the container_of based method used today.
Mike Christie [Fri, 14 Dec 2007 22:57:42 +0000 (14 16:57 -0600)]
update compat patches
update compat patches to remove fuzz warnings from sync up with
dev_printk patch and conn attr patch.
Mike Christie [Fri, 14 Dec 2007 22:50:29 +0000 (14 16:50 -0600)]
iscsi class: fix iscsi conn attr counter
There are 13 iscsi conn attrs, but since the IF/OF markers were not being
used we did not notice that we forgot to increment the ISCSI_CONN_ATTRS
counter.
Mike Christie [Fri, 14 Dec 2007 22:48:47 +0000 (14 16:48 -0600)]
iscsi class: fix iscsi conn attr counter
There are 13 iscsi conn attrs, but since the IF/OF markers were not being
used we did not notice that we forgot to increment the ISCSI_CONN_ATTRS
counter.
Mike Christie [Fri, 14 Dec 2007 22:47:47 +0000 (14 16:47 -0600)]
libiscsi: fix setting of nop timer
If we rollover then we could get a next_timeout of zero, so we need
to set the new timer to that value.
Mike Christie [Fri, 14 Dec 2007 18:54:30 +0000 (14 12:54 -0600)]
fix up Makefile install_etc fix
from Albert:
Need some ;\ to break up lines.
Mike Christie [Fri, 14 Dec 2007 18:12:02 +0000 (14 12:12 -0600)]
sync up nop defaults
iscsi_settings.h uses the old default nop settings. They
were longer than the 5 secs we use now, because they were
sent every noop_out_interval. Now we only send a nop if
we have not got any traffic in noop_out_interval secs.
Mike Christie [Fri, 14 Dec 2007 17:14:56 +0000 (14 11:14 -0600)]
Makefile patch, don't overwrite iscsid.conf when re-installing
from Albert Pauw:
After a git update I reinstall open-iscsi, unfortunately everytime the iscsid.conf file gets overwritten with the standard one.
So I made this patch which doesn't overwrite it, if it exists.
This way I don't have to remember to re-edit it (e.g. isns server settings).
Albert
Mike Christie [Thu, 13 Dec 2007 00:24:27 +0000 (12 18:24 -0600)]
print kernel session state
drivers like qla4xxx do not use iscsid's state machine (there
sm is in hw), so iscsid cannot print the state of the session
or connection. In the kernel we export the session state, so
this patch has iscsiadm print it with the other state values
when running iscsiadm -session -P 1.
Mike Christie [Thu, 13 Dec 2007 00:08:39 +0000 (12 18:08 -0600)]
update 2.6.14-19_compat.patch
update 2.6.14-19_compat.patch for linux-2.6-iscsi 2.6.25 sync up
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>