TCPKEEPALIVE (JANUS DEFINE parameter): Difference between revisions
mNo edit summary |
m (remove displaytitle) |
||
(12 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
<span class="pageSubtitle">Use TCP Keepalives</span> | |||
<span class="pageSubtitle" | |||
TCPKEEPALIVE is a parameter on [[JANUS DEFINE]], which defines and sets characteristics of a Janus port | <var>TCPKEEPALIVE</var> is a parameter on <var>[[JANUS DEFINE]]</var>, which defines and sets characteristics of a Janus port. | ||
This parameter specifies that connections on the port should use TCP keepalives. TCP keepalives request that the TCP stack send periodic "keepalive" packets to the communications partner to see if it is still there. The time interval between these packets, which cannot be set by Janus, is set in the TCP/IP stack configuration. For example, with the IBM stacks, the keepalive interval is set in the TCPCONFIG INTERVAL parameter for BPX (IBM Communications Server) and in the KEEPALIVEOPTIONS INTERVAL parameter for VM TCP/IP. | This parameter specifies that connections on the port should use TCP keepalives. TCP keepalives request that the TCP stack send periodic "keepalive" packets to the communications partner to see if it is still there. The time interval between these packets, which cannot be set by Janus, is set in the TCP/IP stack configuration. For example, with the IBM stacks, the keepalive interval is set in the TCPCONFIG INTERVAL parameter for BPX (IBM Communications Server) and in the KEEPALIVEOPTIONS INTERVAL parameter for VM TCP/IP. | ||
In some sense, the term "keepalive" is a misnomer | In some sense, the term "keepalive" is a misnomer — keepalive packets that are not responded to cause a connection to be closed, so keepalives actually cause connections to be closed faster than they might be otherwise. | ||
TCPKEEPALIVE probably only makes sense for ports where connections are held open for long periods of time. TNSERV ports are the most likely candidate. For these ports, TCPKEEPALIVE might be useful for two reasons: | <var>TCPKEEPALIVE</var> probably only makes sense for ports where connections are held open for long periods of time. <var>[[JANUS DEFINE#type|TNSERV]]</var> ports are the most likely candidate. For these ports, <var>TCPKEEPALIVE</var> might be useful for two reasons: | ||
<ol> | <ol> | ||
Line 15: | Line 14: | ||
</ol> | </ol> | ||
Since the TCP/IP stack does the keepalives, the overhead in | Since the TCP/IP stack does the keepalives, the overhead in <var class="product">Model 204</var> for setting this parameter is virtually zero. | ||
This parameter is only available in | This parameter is only available in <var class="product">Sirius Mods</var> Version 6.9 and later. | ||
TCPKEEPALIVE is valid for all port types. | <var>TCPKEEPALIVE</var> is valid for all port types. | ||
== | ==See also== | ||
<ul> | |||
<li>[[List of Janus commands]] | |||
<li>[[JANUS DEFINE#parmlist|List of JANUS DEFINE parameters]] | |||
</ul> | |||
[[Category:JANUS DEFINE parameters|TCPKEEPALIVE]] | [[Category:JANUS DEFINE parameters|TCPKEEPALIVE]] |
Latest revision as of 00:09, 8 June 2016
Use TCP Keepalives
TCPKEEPALIVE is a parameter on JANUS DEFINE, which defines and sets characteristics of a Janus port.
This parameter specifies that connections on the port should use TCP keepalives. TCP keepalives request that the TCP stack send periodic "keepalive" packets to the communications partner to see if it is still there. The time interval between these packets, which cannot be set by Janus, is set in the TCP/IP stack configuration. For example, with the IBM stacks, the keepalive interval is set in the TCPCONFIG INTERVAL parameter for BPX (IBM Communications Server) and in the KEEPALIVEOPTIONS INTERVAL parameter for VM TCP/IP.
In some sense, the term "keepalive" is a misnomer — keepalive packets that are not responded to cause a connection to be closed, so keepalives actually cause connections to be closed faster than they might be otherwise.
TCPKEEPALIVE probably only makes sense for ports where connections are held open for long periods of time. TNSERV ports are the most likely candidate. For these ports, TCPKEEPALIVE might be useful for two reasons:
- It can detect connections lost due to a client failure (say, a turned-off workstation), reducing threads wasted for connections to lost clients.
- It can reassure certain routers, especially those doing network address translation (NAT) that the connection is still active. Some routers will stop routing packets for connections on which no activity is seen for some period of time. Keepalives ensure that there is periodic activity on a connection, even if there is no user interaction. Of course, for this to be successful, the TCP/IP stack's keepalive interval must be less than any applicable router's inactivity timeout. For this particular application, keepalives live up to their name.
Since the TCP/IP stack does the keepalives, the overhead in Model 204 for setting this parameter is virtually zero.
This parameter is only available in Sirius Mods Version 6.9 and later.
TCPKEEPALIVE is valid for all port types.