Attachmate Worldwide  |   Contact Us  |   NetIQ.com
Home » Support » Solution Library

Technical Notes

TN3270 Host or Printer Connection Terminated When Idle
Technical Note 2353
Last Reviewed 18-Jul-2008
Applies To
EXTRA! X-treme version 8.0 or higher
Summary

The TN3270 host or printer, or any intermediate device between the server and the EXTRA! client, may be configured to terminate connections after a set amount of idle time. This technical note explains how to enable and configure EXTRA! and the Microsoft Windows TCP/IP protocol to send a keep-alive signal to the server at a set interval, to maintain an active connection.

About KeepAlive

The KeepAlive parameter enables the server or client to determine when a Telnet or TCP/IP connection is no longer valid. When a set amount of time elapses with no keep alive signal being received, the computer assumes that the connection has been terminated and that it may now reset the port or socket, making that resource available for further use.

A keep-alive signal can be sent from the server or the client.

Server-initiated keep-alive: EXTRA! X-treme supports TN3270 server-initiated keep-alive, including outbound NOP (No OPeration) and Timing Mark commands from the TN3270 server.

Server-initiated keep-alive is useful if

  • You have sufficient rights to enable the server keep-alive feature, and
  • There is a direct connection between the server and the client, with no intermediary devices, such as proxy servers or firewalls that may have their own keep-alive timeout configurations.

Client-initiated keep-alive: EXTRA! X-treme does not support outbound application level client-initiated keep-alive (like the NOP or Timing Mark commands); however, it can be configured to support the Microsoft Windows TCP/IP level keep-alive parameter.

Client-initiated keep-alive is useful if

  • You are unable to configure server-side keep-alive, or
  • There are intermediary devices, such as proxy servers or firewalls which may have their own keep alive timeout configurations.

The remainder of this technical note describes how to configure client-initiated keep-alive.

Enabling Keep-alive Support in EXTRA!

To enable client-initiated keep-alive support, you must configure EXTRA! to use the Microsoft TCP/IP KeepAlive parameter. Follow these steps:

  1. Close any open EXTRA! host sessions.
  2. In a plain text editor, such as Notepad, open the EXTRA! session configuration or EDP file you are using for the TN3270 session. (To enable the KeepAlive parameter in all newly created TN3270 sessions, modify the 3270.EDP file.)

By default, this file is located at C:\Program Files\Attachmate\EXTRA!\Sessions\ENU\Template\3270.EDP.

  1. In your EDP file, scroll down to the [Connection] heading.
  2. Add the following line to the [Connections] section.
KeepAlive=YES

Or, to disable this feature (the default), delete the line or change the value to NO.

KeepAlive=NO
  1. Save the file.
  2. Restart EXTRA!.

Configuring Microsoft TCP/IP KeepAlive Support

By default, when enabled by the application, the Microsoft TCP/IP KeepAlive parameter is configured to verify that a connection is still valid every two hours. Depending on your network environment, you may need to reduce or increase this frequency interval.

The KeepAlive parameters are configured through the Windows Registry Editor.

Warnings:

  • Adjusting the following parameters may affect Windows TCP/IP-based applications besides EXTRA!. Proceed with caution and test thoroughly before changing these values in a production environment.
  • You must have Administrative rights on the Windows workstation to adjust these parameters.
  • Proceed with extreme caution when editing the Windows registry. It is critical to back up the registry before you proceed. For full details and warnings regarding editing the Windows registry, see Microsoft Article 322756:

The following parameters affect TCP/IP KeepAlive:

KeepAliveTime

Controls how often TCP attempts to verify that an idle connection is still valid by sending a keep alive packet to the server and waiting for an acknowledgement. The default is 7,200,000 (2 hours). Decrease this value to verify and idle the connection more frequently.

KeepAliveInterval

Controls how frequently the keep alive packet is resent if no response is received from the host. Increasing this value gives the server more time to reply to the request before a new request is sent.

TcpMaxDataRetransmissions

Controls how many times TCP resends a package (as the specified KeepAliveInterval) with no reply before the connection is terminated. Increasing or decreasing this value gives the server more or less time to respond.

For more information about TCP/IP parameters, see the following Microsoft articles:

  • Windows Vista:
  • Windows XP
  • Windows 2000

To configure the TCP/IP KeepAlive parameters:

  1. Click Start > Run, in the Open field, enter regedit, and then click OK.
  2. Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters.
  3. Right-click the Parameters folder, then click New > Binary Value.
  4. Change the Name of the new key to one of the KeepAlive parameter names: KeepAliveTime, KeepAliveInterval, or TcpMaxDataRetransmissions.
  5. Right-click the parameter, and click Modify.
  6. Enter the time value that is appropriate for your network environment in the Value data field. Values are in thousands of a second (milliseconds), where 1000 = 1 second.
  7. Click OK.
  8. Exit the Registry Editor and restart your computer.
Related Technical Notes
9970 Technical Notes for EXTRA!

Did this technical note answer your question?

Yes    No    Somewhat     Not sure yet

Additional comments about this tech note:

Need further help? For technical support, please contact Support.