Session

Topics: User Forum
Nov 6, 2009 at 9:44 AM

Hallo,

I allway get an error, when I want to connect to an existing server: "connect to example.server.org on port 23 failed". But when I use a terminal emulation software i can conncet. Where is the Problem? When using diffferent terminal emulation software i have to send as short name "A" to the server. How can I send the short name with the Open TN3270 Library?

Are there any examples?

Dec 1, 2009 at 6:43 PM

Terminal emulation that requires you to send an "A" is based upon using the HLLAPI and connects to an existing 3270 session, think Rumba, Blue Zone, QWS3270, etc.  This is a stand-alone 3270 on its own, so you need the IP, the port, and the LU.  Here is an example from my code:

TN3270Audit auditLog = new TN3270Audit();
TNEmulator emulator = new TNEmulator();
emulator.Config.FastScreenMode = false;
emulator.Config.DefaultTimeout = 3000;
emulator.Config.TermType = "IBM-3278-2-E";
emulator.Config.HostPort = 23;
emulator.Config.HostName = "my.servername.com";
emulator.Audit = auditLog;
emulator.Config.ThrowExceptionOnLockedScreen = true;
emulator.Debug = true";
emulator.Config.HostLU =  "your_mainframe_LU";
emulator.Connect(); 

Dec 16, 2009 at 7:25 AM

I have made the connection with the IP, the port, and the LU.
I allways get the error "HostException 'connect to xyz.host.com on port 23 failed' Timeout waiting
for connection", but with a terminal emulation programm i'll get an connection. Where ist the problem?
Is it possible that I have a problem with the local IP?
When starting my test-programm there is no local-ip:
Connect to host "xyz.host.com"
           port "23"
           LU   "CICSE3M3"
     Local IP   ""
    
How can I find and solve the problem?

 

Dec 18, 2009 at 2:55 PM

I have never needed to use the localIP setting, so it shouldn't matter.  Can you post the output from running the demo that shows the problem?

Dec 21, 2009 at 6:22 AM
Edited Dec 21, 2009 at 6:22 AM

Here is the output from the running demo:
-----------
Open3270 emulator version 1.5.0.1
(c) 2004-2006 Mike Warriner (mikewarriner@gmail.com). All rights reserved

Config.FastScreenMode True
Config.IgnoreSequenceCount False
Config.IdentificationEngineOn True
Config.AlwaysSkipToUnprotected True
Config.LockScreenOnWriteToUnprotected False
Config.ThrowExceptionOnLockedScreen True
Config.DefaultTimeout 200000
Config.hostName xyz.host.com
Config.hostPort 23
Config.hostLU CICSE3M3
Config.termType IBM-3278-2-E
Config.AlwaysRefreshWhenWaiting False
Config.SubmitAllKeyboardCommands False
Config.RefuseTN3270E False
Connect to host "unr53720.ges.bauboden.com"
           port "23"
           LU   "CICSE3M3"
     Local IP   ""
HostException 'connect to xyz.host.com on port 23 failed' Timeout waiting for connection
System.Collections.ListDictionaryInternal
-------------

For your Information ist here the code:
-------------
TNEmulator emulator = new TNEmulator();
emulator.Audit = this;
emulator.Debug = true;
emulator.Config.TermType = "IBM-3278-2-E";
emulator.Config.HostPort = 23;
emulator.Config.HostName = "xyz.host.com";
emulator.Audit = this;
emulator.Config.ThrowExceptionOnLockedScreen = true;
emulator.Config.HostLU = "CICSE3M3";
emulator.Config.FastScreenMode = true;
emulator.Config.DefaultTimeout = 200000;
emulator.Config.RefuseTN3270E = false;
emulator.Config.IdentificationEngineOn = true;
Console.WriteLine(emulator.LocalIP);
try
{
    emulator.Connect();
}
catch (TNHostException e)
{
    Console.WriteLine(e);
    Console.WriteLine(e.Data);
    Console.ReadLine();
    return;

}
...
--------------
For testing I have changed all config options. But the result is allways the same!
Is it possible that I need the LU of my client? Where can I adjust the LU or IP-adress of my client if necessary?
To connect with the host I have to adjust an allowed IP-adress to my client.

Here is the connection-status from the terminal-emulation program:

Status: LU-LU
Host Adress: 194.196.27.56
Terminalname: IBM-3278-2-E
Logical Unit Name: TCX8TQ5
Primary LU: CICSE3M3
Secondary LU:

Where is the problem?

 

 

Dec 21, 2009 at 1:16 PM
Is the LU CICSE3M3 on the mainframe, or TCX8TQ5?
Also, I have not had much luck using this option: emulator.Config.IdentificationEngineOn = true;
So I usually have it set to false.
Are you running this in DEBUG and stepping through to watch it try to make the connection?  This would certainly give you more clues to work from.
Dec 21, 2009 at 4:02 PM

Yep, I'm having the same exact problem - connection timeout. I've tried the emulator on several servers without a problem, but on the one I need to connect to, I'm getting a timeout. Using commercial 3270 applications, I can connect without a problem. I've run debug mode, but it's basically just giving me the settings I've configured, and then, after a delay, giving the simple timeout error. No other information is given. It's driving me crazy.

Dec 21, 2009 at 5:35 PM

The mainframe LU is CICSE3M3. When I set the option "emulator.Config.IdentificationEngineOn" to false I get the same error. Also, I was debugging the code with stepping deep into the code, but it wasn't giving me any conclusion. I have the same problems as ylibrach, when debbuging the code. I'm getting very angry! Please HELP me!

 

Dec 22, 2009 at 5:58 PM

When I debug the code, the problem happens in Open3270.TN3270.Telnet, inside function Connect(object _ParentData, string _address, int _port), on the line that says mSocketBase.BeginConnect(iep, callbackProc, mSocketBase).

After a few seconds, the callback (ConnectCallback) is called, at which point it throws the timeout error.

Feb 8, 2010 at 7:40 PM

Did you ever get this to connect?

Feb 24, 2010 at 7:03 PM

No, I never get this connect. The problem isn't solved.

Feb 24, 2010 at 7:48 PM

I'm guessing the IP 194.196.27.56 is not available for e eto connect to?  I am unable to connect to the server you mention either, though I imagine it is on your internal network and not available to me.  I'll be glad to try to assist, but you will have to give me more information.  I have several applications i have used this library in without a problem. 

Did you try to connect to the public mainframe I mentioned in another post in the forum?

Feb 25, 2010 at 7:23 AM

The Mainframe behind the IP cannot be reached on public. I can connect to the public mainframe without problems, you have mentioned in another post. I think the problem is the configuration of the mainframe I try to connect to. Which further information do you need? And how can I get more information about the mainframe?

 

 

May 7, 2010 at 4:13 PM

I was having the same problems establishing a session.  First of all, the library of congress doesn't work anymore as a test connection.  However, the real problem with the library is that when they started merging different people's trunks and branches, things stopped working.  I don't know why they didn't do some testing and notice this.  The last working version is 55326.

Here's the url:

http://open3270.codeplex.com/SourceControl/changeset/changes/55326

 

Sep 19, 2010 at 12:21 PM

Yes, that was the error! With the version 55326 the Problem is solved!

Thank you very much.

Coordinator
Nov 5, 2010 at 12:42 PM
blakeje2010 wrote:

I was having the same problems establishing a session.  First of all, the library of congress doesn't work anymore as a test connection.  However, the real problem with the library is that when they started merging different people's trunks and branches, things stopped working.  I don't know why they didn't do some testing and notice this.  The last working version is 55326.

Here's the url:

http://open3270.codeplex.com/SourceControl/changeset/changes/55326

 

I have only one server on which I can test. And the merges worked fine on that. So I would appreciate some help to figure out which merge caused the problem. Keep in mind there were lots of patches floating around in the discussions, some of which caused conflicts, because different people were trying to solve the same problem. It's probably that when I tried to resolve one of these conflicts it messed up something.

Nov 5, 2010 at 1:07 PM
PGh0bWw+PGJvZHkgYmdjb2xvcj0iI0ZGRkZGRiI+PGRpdj5JdCB3b3JrcyBm aW5lIGZvciBtZSBhcyB3ZWxsLiAmbmJzcDtJIGhhdmUgYmVlbiB1c2luZyBp dCBpbiBhcHBzIGZvciB3b3JrIHNpbmNlIG15IGZpcnN0IHBvc3Rpbmc8YnI+ PGJyPjxicj48L2Rpdj48ZGl2Pjxicj5PbiBOb3YgNSwgMjAxMCwgYXQgNzo0 MiBBTSwgImlnaXR1ciIgJmx0OzxhIGhyZWY9Im1haWx0bzpub3RpZmljYXRp b25zQGNvZGVwbGV4LmNvbSI+bm90aWZpY2F0aW9uc0Bjb2RlcGxleC5jb208 L2E+Jmd0OyB3cm90ZTo8YnI+PGJyPjwvZGl2PjxkaXY+PC9kaXY+PGJsb2Nr cXVvdGUgdHlwZT0iY2l0ZSI+PGRpdj4gPHN0eWxlPkJvZHl7Zm9udC1mYW1p bHk6IFZlcmRhbmE7IGZvbnQtc2l6ZTogMC43NWVtO30jVGhyZWFkTm90aWZp Y2F0aW9uRm9vdGVye2NvbG9yOiBncmF5OyBib3JkZXItdG9wOiAxcHggc29s aWQgI2NjYzt9I1RocmVhZE5vdGlmaWNhdGlvblBvc3RCb2R5e01hcmdpbi1C b3R0b206IDJlbTt9PC9zdHlsZT48cD5Gcm9tOiBpZ2l0dXI8L3A+IDxkaXYg aWQ9IlRocmVhZE5vdGlmaWNhdGlvblBvc3RCb2R5Ij4NCjxibG9ja3F1b3Rl IHN0eWxlPSJib3JkZXI6c29saWQgLjFlbSAjY2NjOyBmb250LXN0eWxlOml0 YWxpYzsgbWFyZ2luOi4yNWVtIDFlbSAwIDFlbTsgcGFkZGluZzowIC4yNWVt IDAgLjI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