Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 715327

Summary: vdsm: cannot login to node when there are more them 190 targets in iscsi db
Product: Red Hat Enterprise Linux 6 Reporter: Dafna Ron <dron>
Component: vdsmAssignee: Dan Kenigsberg <danken>
Status: CLOSED ERRATA QA Contact: Dafna Ron <dron>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: abaron, bazulay, coughlan, danken, dron, iheim, mchristi, yeylon, ykaul
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: storage
Fixed In Version: vdsm-4.9-79 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 715312 Environment:
Last Closed: 2011-12-06 07:23:06 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 715312    
Bug Blocks:    
Attachments:
Description Flags
vdsm log none

Description Dafna Ron 2011-06-22 14:35:57 UTC
Created attachment 506023 [details]
vdsm log

+++ This bug was initially created as a clone of Bug #715312 +++

This is a duplicated to a bug opened to iscsi where targets exceed 190 for session and we cannot login to node. 

vdsm error is Error during storage connection: Remove iSCSI node error
when in fact the actual error is that we are unable to login. 

As a result the host will become Non-Operational and backend will show RHEVM internal error message. 

Danken has emplimented a test fix on my host to allow non persistent  connections and cleaning /var/lib/iscsi/nodes/*/*/default

I was then able to connect. 

1) if we can issue some kind of fix we should since 190 targets per 1 connection is not that many. 
2) we should have a correct error message for this issue - where implementation in backend side will also offer a manual solution to administrator. 

Created attachment 506014 [details]
log

Description of problem:

working with the rhevm and iscsi I was trying to connect my host to my iscsi lun. 
I was getting an error for command: /sbin/iscsiadm -m node -T Dafna-blonds-Linux -l -p 10.35.64.10:3260

after some digging we found that we have exceeded 190 targets on the same connection and there for were unable to login. 
 
after removing the nodes under /var/lib/iscsi/nodes/*/*/default and discover again -  we were able to connect again to the storage. 

why are we limited to 190 targets? 


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

iscsi-initiator-utils-6.2.0.872-21.el6.x86_64

How reproducible:


Steps to Reproduce:
1. exceed 190 targets under same connection and try to login to lun
2.
3.
  
Actual results:

you cannot login

Expected results:

exceed 190 nodes limit 

Additional info: vdsm log which can show the error we were getting

Comment 1 Dan Kenigsberg 2011-06-22 20:26:21 UTC
after

/sbin/iscsiadm -m node -T Dafna-blonds-Linux -l -p 10.35.64.10:3260

fails, we return

Thread-1245::INFO::2011-06-22 12:33:11,455::dispatcher::100::Storage.Dispatcher.Protect::(run) Run and protect: connectStorageServer, Return response: {'status': {'message': 'OK', 'code': 0}, 'statuslist': [{'status': 459, 'id': 'e2a868c7-40a4-4168-a9f9-6e31b3f73d3d'}]}

where RemoveiSCSINodeError==459. That's unfortunate - we should return iSCSILoginError==464.

That's a minor bug, but its solution is interesting:


From dec3d671cafbcd5c783f94c6f6b1d33e5e40c430 Mon Sep 17 00:00:00 2001
From: Dan Kenigsberg <danken>
Date: Wed, 22 Jun 2011 23:19:57 +0300
Subject: [PATCH] BZ#715327 connectStorageServer: report original error

When connectStorageServer: fails, we try to clean after ourselves.
However, the error code we report should reflect the original cause of
the error, not a consequential error during cleanup.

Change-Id: I032ee0e059228559698bdd14b1dfe360885c6e35
---
 vdsm/storage/iscsi.py |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/vdsm/storage/iscsi.py b/vdsm/storage/iscsi.py
index 59a7573..75f1542 100644
--- a/vdsm/storage/iscsi.py
+++ b/vdsm/storage/iscsi.py
@@ -18,6 +18,7 @@ import tempfile
 import logging
 import socket
 import re
+import sys
 
 import constants
 import misc
@@ -471,6 +472,7 @@ def addiSCSINode(ip, port, iqn, tpgt, initiator, username=None, password=None):
         if rc != 0:
             raise se.iSCSILoginError(portal)
     except se.StorageException:
+        exc_class, exc, tb = sys.exc_info()
         try:
             if checkSession(ip, port, iqn, tpgt, username, password):
                 return 0
@@ -482,7 +484,7 @@ def addiSCSINode(ip, port, iqn, tpgt, initiator, username=None, password=None):
         except Exception:
             log.error("Could not remove iscsi node", exc_info=True)
 
-        raise
+        raise exc_class, exc, tb
 
 
 def remiSCSINode(ip, port, iqn, tpgt, username=None, password=None, logout=True):
-- 
1.7.4.4

Comment 2 Dan Kenigsberg 2011-06-23 11:03:31 UTC
http://gerrit.usersys.redhat.com/615

Comment 5 Dafna Ron 2011-07-14 15:35:32 UTC
wasn't able to reproduce. 
verified for vdsm-4.9-81

Comment 6 errata-xmlrpc 2011-12-06 07:23:06 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2011-1782.html