Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TSIH (Target Session Identifying Handle) is missing? #24

Open
felipegutierrez opened this issue Mar 8, 2015 · 1 comment
Open

TSIH (Target Session Identifying Handle) is missing? #24

felipegutierrez opened this issue Mar 8, 2015 · 1 comment

Comments

@felipegutierrez
Copy link

Hello,
I wonder to know about the commentary at https://github.com/sebastiangraf/jSCSI/blob/master/bundles/target/src/main/java/org/jscsi/target/TargetServer.java#L232
It says about TSIH that should be implemented at the future. I would like to help to implement it based at http://www.ietf.org/rfc/rfc3720.txt:

  • TSIH (Target Session Identifying Handle): A target assigned tag for
    a session with a specific named initiator. The target generates it
    during session establishment. Its internal format and content are
    not defined by this protocol, except for the value 0 that is
    reserved and used by the initiator to indicate a new session. It
    is given to the target during additional connection establishment
    for the same session.
    Based on the RFC 3720 I should get the session IDs and build these actions:

+------------------------------------------------------------------+
|ISID | TSIH | CID | Target action |
+------------------------------------------------------------------+
|new | non-zero | any | fail the login |
+------------------------------------------------------------------+
|new | zero | any | instantiate a new session |
+------------------------------------------------------------------+
|existing | zero | any | do session reinstatement |
+------------------------------------------------------------------+
|existing | non-zero | new | add a new connection to |
+------------------------------------------------------------------+
|existing | non-zero |existing| do connection reinstatement|
+------------------------------------------------------------------+
|existing | non-zero | any | fail the login |
+------------------------------------------------------------------+

Looks like the TargetSession has the ISID and TSIH but CID (ConnectionID) where is?
Am I correct? Could you give me any advice? Like if I have to create new classes? Which methods?
Thanks in advanced. Felipe

@felipegutierrez
Copy link
Author

Hi, I have some thing I think is related to it. The original problem is that after 10 hours of my microsoft iscsi initiator connect to the jSCSI target, the initiator try to reconnect, maybe a connection reinstatement, and it can't. I think it is related to ERROR_RECOVERY_LEVEL https://github.com/sebastiangraf/jSCSI/blob/master/bundles/target/src/main/java/org/jscsi/target/settings/SessionSettingsNegotiator.java#L155 that is set to 0 (zero) at target and 2 (two) at microsoft iscsi initiator.
Is that possible? Should I set both to zero?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant