<p class="MsoNormal">Hi Andrei,</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">Sorry I forgot to answer all your questions in my last
email.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">This is the version of kamailio (we are running it on CentOS
5.5, 64 bit with 8 Cores Xenon processor, 8 GB RAM), &amp; we are starting
kamailio with 2 GB shared memory.</p>

<p class="MsoNormal">version: kamailio 3.1.2 (x86_64/linux)</p>

<p class="MsoNormal">flags: STATS: Off, USE_IPV6, USE_TCP, USE_TLS, TLS_HOOKS,
USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP,
PKG_MALLOC, DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES</p>

<p class="MsoNormal">ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144,
MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, PKG_SIZE 4MB</p>

<p class="MsoNormal">poll method support: poll, epoll_lt, epoll_et, sigio_rt,
select.</p>

<p class="MsoNormal">id: unknown</p>

<p class="MsoNormal">compiled on 10:32:48 Mar  7 2011 with gcc 4.1.2</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">We are using kamailio as a router for SIP messages. We
connect kamailio with OCS Access proxy &amp; sends traffic.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">We have two Access proxies, each creates up to 32 TCP /TLS
connections. And sends over 5000 messages/sec. So there is not enough connected
socketa for kamailio but we frequently close the sockets for testing.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">We are running kamailio with 8 TCP children. &amp; when it
crashes it generates mostly 2 core files.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">There is defiantly a race condition inside the code which I
have fixed it but it was not related to the tcp connection management.  I
will send you the code soon or submit it to the dev group. It is inside timer
code.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">For this 100% cpu problem, the linked list is circular. May
be the code that adds/removes TCP connection to linked list is not perfect.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">Regards</p>

<p class="MsoNormal">-Zunnun</p>

<p class="MsoNormal"> </p>