[SR-Users] Configuring TCP keep alive and connection lifetime

Pascal Maugeri pascal.maugeri at gmail.com
Fri May 7 16:20:42 CEST 2010


"kamailio" <users at lists.kamailio.org>,

Hi

I am sorry to ask again about this topic but I don't understand yet how the
TCP keep-alive are sent.

With Kamailio 3.0.1 and the following configuration:

tcp_keepalive=yes
tcp_keepidle=10
tcp_connection_lifetime=3600


The TCP connection is kept alive and TCP Keep-Alive packets are sent when
the TCP connection is idle.

But I don't understand why the time between KA is not linear:

first KA is sent 10 seconds after last last TCP message. This is logical and
connected with the tcp_keepidle=10 configuration.

then 2nd KA is sent 75 seconds after first KA

Then my client sends some traffic and 23 seconds after last message, a new
KA is sent. Another time it was 54 seconds. etc. etc.

Could you explain me where do come from these values of 75 seconds, 23, 54 ?

Everything works well: my client behind NAT is kept connected but I'd like
to understand why it does work :-)

Thanks in advance,
Pascal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20100507/c6eb422c/attachment.htm>


More information about the sr-users mailing list