About the KeepAlive Parameter
The KeepAlive parameter enables the server or client to determine when a Telnet, TLS, 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 keepalive signal can be sent from the server or the client.
Server-initiated keepalive: EXTRA! X-treme supports TN3270 and TN5250 server-initiated keepalive, including outbound NOP (No OPeration) and Timing Mark commands from the server.
Server-initiated keepalive is useful if
- You have sufficient rights to enable the server keepalive 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 keepalive timeout configurations.
Client-initiated keepalive: EXTRA! X-treme does not support outbound application level client-initiated keepalive (like the NOP or Timing Mark commands); however, it can be configured to support the Microsoft Windows TCP/IP level KeepAlive parameter.
Client-initiated keepalive is useful if
- You are unable to configure server-side keepalive, or
- There are intermediary devices, such as proxy servers or firewalls which may have their own keep alive timeout configurations.
Enabling Keepalive Support in EXTRA!
To enable client-initiated keepalive support, you must configure EXTRA! to use the Microsoft TCP/IP KeepAlive parameter. Follow these steps:
- Close any open EXTRA! host sessions.
- 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\Micro Focus\EXTRA!\Sessions\ENU\Template\3270.EDP.
- In your EDP file, scroll down to the [Connection] heading.
- Add the following line to the [Connections] section.
Or, to disable this feature (the default), delete the line or change the value to FALSE.
- Save the file.
- 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.
- Adjusting the following parameter 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: http://support.microsoft.com/kb/322756/
The following parameter affect TCP/IP KeepAlive:
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.
- Click Start > Run, in the Open field, enter regedit, and then click OK.
- Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters.
- Right-click the Parameters folder, then click New > DWORD Value.
- Change the Name of the new key to "KeepAliveTime".
- Right-click the parameter, and click Modify.
- Enter the time value (in decimal) that is appropriate for your network environment in the Value data field. Values are in thousands of a second (milliseconds), where 1000 = 1 second.
- Click OK.
- Exit the Registry Editor and restart your computer