Bug 176231 - Stale iSCSI session stays active after removing the target permanently
Stale iSCSI session stays active after removing the target permanently
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: iscsi-initiator-utils (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Mike Christie
Depends On:
Blocks: 170416
  Show dependency treegraph
Reported: 2005-12-20 07:42 EST by Chakravarthy G.R.K.
Modified: 2007-11-30 17:07 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-07-21 10:36:47 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Fix for the bug (3.99 KB, patch)
2005-12-20 07:42 EST, Chakravarthy G.R.K.
no flags Details | Diff

  None (edit)
Description Chakravarthy G.R.K. 2005-12-20 07:42:56 EST
Description of problem:

Two targets are connected to MDS. One of which is available only if the other 
is removed permanently(a dynamic target is created). The MDS is connected to 
the initiator.

After removing the first iscsi target only the dynamic target is sent to the 
initiator on a SendTargets respose. So it sets up a session for the new target. 
But the older session (stale session) still remains and login is unecessarily 
retried on a permanently removed target.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Make sure that all targets and iSCSI sessions are up.
2. Remove the target on MDS
3. Check the iSCSI sessions on the initiator.
Actual results:
The initiator tries to login into a permanently removed target. It does not 
tear down the older sessions

Expected results:
The initiator should tear down all the old sessions, once the new dicovery 
responds with dissimilar targets.

Additional info:
Comment 1 Chakravarthy G.R.K. 2005-12-20 07:42:57 EST
Created attachment 122444 [details]
Fix for the bug
Comment 2 Mike Christie 2006-03-21 18:37:35 EST

what is the reason for if session not alive test?

+	dlist_for_each_data(device_list, cldev, struct sysfs_class_device) {
+		sprintf(name, "host%d", host_list[i]);
+		if (!strncmp(cldev->name, name, strlen(name))) {
+			attr1 = sysfs_get_classdev_attr(cldev,
+						"session_established");
+			sscanf(attr1->value, "%d", &session_alive);
+			if (!session_alive) {
Comment 3 Tom Coughlan 2006-04-10 07:57:02 EDT
No reply since December. Low priority. Does not happen frequently. 

We are not planning to address this in U4. Possibly in a later update. 
Comment 5 RHEL Product and Program Management 2006-07-21 10:36:48 EDT
Development Management has reviewed and declined this request.  You may appeal this decision by reopening this request.

Note You need to log in before you can comment on or make changes to this bug.