The connection registered by the client is normal, and the client can send messages and renew the registration normally, but the push message to the client using uac_req_send() from kamailio fails. Location information after the client is registered:
]#kamcmd ul.lookup location test01 Received: sip:10.11.40.XX:57646;transport=tls
]#netstat -anp | grep 57646 "tcp 0 0 10.11.55.xx:5061 10.11.40.XX:57646 ESTABLISHED 3467/kamailio"
kamailio.lua KSR.pv.sets("$uac_req(ouri)", rows.received)
In this way, most users can receive messages normally, but occasionally some users cannot receive messages but can renew their registration and send messages normally. Once this is the case for this user, the use of uac_req_send() will continue to fail until the client establishes a new connection.
If a problem occurs, the following logs are displayed on the server: 2024-02-20T10:01:25.329595+08:00 10.11.55.XX (72819) ERROR: <core> [core/tcp_main.c:4692]: tcpconn_main_timeout(): connect 10.11.40.XX:57646 failed (timeout)
The connection already exists and should be normal, why does "tcpconn_main_timeout(): connect 10.11.40.XX:57646 failed (timeout)" occur.