[Koha-bugs] [Bug 31033] SIP2 does not correctly handle multiple simultaneous connections

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jun 24 03:21:00 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31033

David Cook <dcook at prosentient.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dcook at prosentient.com.au

--- Comment #1 from David Cook <dcook at prosentient.com.au> ---
That's quite interesting.

Using koha-testing-docker, I ran "telnet localhost 6001" from two different
terminals. In a third terminal, I ran the following "ss -l -n -t" and I can see
that the SIP process listening on 127.0.0.1:6001 has 1 connection in its TCP
"listen" backlog. 

While the telnet client says it's connected, that just mean it's connected to
the server's network stack. Only one connection has actually been accepted by
the application. (This would probably be clear from your prod syslog as well.)

Looking at the "server-params" in the SIPconfig.xml file, it looks like
min_servers = 1 and min_spare_servers = 0. In theory, 0 should be fine because
that should just means 0 spare servers...

When I change min_spare_servers to = 1, the forking seems to work correctly. If
there are no current connections, then there is only 1 child process. If there
are current connections, then it keeps 1 extra connection around. 

I'd say it's a bug/quirk in Net::Server::PreFork which powers the SIP server. 

Since it looks like the SIP server has accidentally been using a max of 1 child
process, we should probably set some limits on maximums since the default max
server is 50. The default max spare servers is 10...

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.


More information about the Koha-bugs mailing list