[OpenSIPS-Users] TCP keepalive problem.
Volkan Oransoy
voransoy at gmail.com
Sat Aug 24 11:06:04 UTC 2024
Hi all,
I have an interesting issue that I am trying to identify the cause of. I am
trying to migrate a quite old Kamailio SIP proxy to OpenSIPS 3.4. The new
OpenSIPS proxy uses mid_registrar and replicates registrations to the
backend boxes.
A specific type of UACs (Gigaset AS690) does not keep the TCP connection
alive. So on every registration refresh, the traffic comes from another
port and a new contact is created. Interestingly, there are UACs from the
very same network that have a healthy connection to the OpenSIPS box.
Since this is not an issue with the old box, I assume the issue is related
to my new setup.
When sniffing the traffic, I see that the UAC ends the connection.
11 9.378043 UAC_IP SERVER_IP TCP 60 22719 → 5060 [SYN] Seq=0 Win=1608 Len=0
MSS=536
12 9.378148 SERVER_IP UAC_IP TCP 58 5060 → 22719 [SYN, ACK] Seq=0 Ack=1
Win=64240 Len=0 MSS=1460
13 9.401441 UAC_IP SERVER_IP TCP 60 22719 → 5060 [ACK] Seq=1 Ack=1 Win=1608
Len=0
14 9.405625 UAC_IP SERVER_IP SIP 560 Request: REGISTER sip:c384.bulutfon.net
(1 binding) |
15 9.405731 SERVER_IP UAC_IP TCP 54 5060 → 22719 [ACK] Seq=1 Ack=507
Win=63784 Len=0
16 9.405863 SERVER_IP UAC_IP SIP 557 Status: 401 Unauthorized |
17 9.434851 UAC_IP SERVER_IP TCP 60 22719 → 5060 [ACK] Seq=507 Ack=504
Win=1608 Len=0
18 9.464046 UAC_IP SERVER_IP SIP 756 Request: REGISTER sip:c384.bulutfon.net
(1 binding) |
19 9.470312 SERVER_IP UAC_IP TCP 590 5060 → 22719 [ACK] Seq=504 Ack=1209
Win=63784 Len=536 [TCP segment of a reassembled PDU]
20 9.470337 SERVER_IP UAC_IP SIP 125 Status: 200 OK (REGISTER) (2
bindings) |
21 9.495625 UAC_IP SERVER_IP TCP 60 22719 → 5060 [ACK] Seq=1209 Ack=1040
Win=1608 Len=0
22 9.501248 UAC_IP SERVER_IP TCP 60 22719 → 5060 [ACK] Seq=1209 Ack=1111
Win=1608 Len=0
23 10.520457 UAC_IP SERVER_IP TCP 60 22719 → 5060 [FIN, ACK] Seq=1209
Ack=1111 Win=1608 Len=0
24 10.520701 SERVER_IP UAC_IP TCP 54 5060 → 22719 [FIN, ACK] Seq=1111
Ack=1210 Win=63784 Len=0
25 10.543913 UAC_IP SERVER_IP TCP 60 22719 → 5060 [ACK] Seq=1210 Ack=1112
Win=1608 Len=0
I use tcp_persistent_flag to flag the TCP connections and I can see the
relevant flag on ul_dump output.
modparam("mid_registrar", "tcp_persistent_flag", "TCP_PERSISTENT")
if ($socket_in(proto) == "tcp" || $socket_in(proto) == "tls")
setbflag("TCP_PERSISTENT");
mid_registrar_save("location");
I have tried disabling the config above and giving a fixed TCP lifetime
value to the OpenSIPS box, but the issue remains the same.
Do you have any hints that I can chase after?
Best
--
Volkan Oransoy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20240824/5aa7a4d5/attachment.html>
More information about the Users
mailing list