<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">
<DIV><FONT face="Times New Roman">Sorry this was originally posted incorrectly, 
so I’m reposting....</FONT></DIV>
<DIV><FONT face="Times New Roman"></FONT>&nbsp;</DIV>
<DIV><FONT face="Times New Roman">I have been having problems with TCP under 
load.&nbsp; What I have been seeing is <BR>TCP buffers failing to be serviced 
and, when wr_timeout exceeds the <BR>configured value for tcp_send_timeout, 
kamailio kills the connection. <BR>Increasing tcp_send_timeout doesn't help, 
even setting this to a big value <BR>(such as 45 seconds) just delays the 
disconnection.<BR><BR>Putting some tracing into the code shows that wbufq_add() 
is repeatedly <BR>called, but wbufq_run() is called for that connection far less 
than I would <BR>expect.&nbsp; wbufq_run() is frequently called for other 
connections.&nbsp; It looks <BR>like wbufq_run() doesn't get called when lots of 
wbufq_add()s are happening <BR>for a connection?&nbsp; wbufq_run() only appears 
to be called for a connection <BR>after some time has passed from the last 
wbufq_add().<BR><BR>The connection in question is a local loopback between the 
RLS and Presence <BR>modules (both running in the same Kamailio instance).&nbsp; 
However, it may just <BR>be a coincidence that this is the affected connection 
as it is also the one <BR>with the most traffic.<BR><BR>My suspicion is that the 
bug is in the io_wait_loop_epoll() routine.<BR><BR>Can anybody with experience 
of this part of the code help?<BR><BR></DIV></FONT>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">Paul 
Pankhurst<BR>Engineering Director<BR>Crocodile RCS 
Ltd<BR></DIV></DIV></DIV></BODY></HTML>