: > Sun SPARC computer systems running Solaris 2.3 or 2.4 have a limit of
: > only 32 simultaneous incoming TCP/IP connections. This means that if
: > you have a web server on a Solaris system set up to handle 64
: > connections, half of those possible connections will never be used.
: Apparently this is indeed true. Sun has indicated that Solaris 2.5 will
: support up to 1,024 connections rather than 32.
This is not so. The supposed hard limit in Solaris 2.4 of 32 backlogged
connections can be raised to any number you want (although I would not go
any higher than 128). Below is an e-mail I sent to Netscape on July 24
outlining a "problem" with their server. I have yet to receive a response.
To whom it may concern (at Netscape Communications),
I have had some problems with the Netscape server 1.1 and Solaris 2.4
running on Sparc20 612 MP. It bogs down under heavy load, and incoming
requests are left unprocessed.
Your technical note #20101 on your Web pages suggest this may be a result
of a limitation of 32 incoming connections for Solaris 2.3/2.4. This is
basically untrue. This specific limitation is within the Netscape server
software, not Solaris.
I have included below a script that will raise the tcp_conn_req_max to any
number you want (I am using 64 right now on my main system and other
active servers). The problem is that your server, when it executes a
listen() system call, hardcodes the "backlog" parameter at 32. Even
though the operating system, after my changes with the script below, has a
larger backlog (and will reduce the backlog to its maximum if a program
requests higher) the netscape server does not utilize it.
I would like Netscape to change the technical note #20101 to reflect the
truth, and not suggest that Solaris is the problem. I also require an
updated version of the Netscape server that has the listen() backlog set
to 1024 (the upcoming Solaris 2.5 maximum), or something even higher. If
I can't then I may be forced to move my server, and 30->40 customers of
ours we well, to NCSA 1.4.2, only because I can modify it myself. I don't
really want to do that.
Please let me know what you can do, even if its nothing.
# script to bump up tcp_conn_req_max > 32 in Solaris 2.4
# This script should be run by root and only by the competent who
# realize that this changes the kernel on the fly and its consequences
# READ THE FOLLOWING BEFORE USING THIS SCRIPT.
# Disclaimer:This is not an officially supported script from Sun
# Warning ! This can affect the behavior of *all* TCP listeners on
# the machine. It has the potential to increase kernel memory useage.
# Since the the tcp_conn_req_max parameter is the limit
# the kernel imposes on the listeners, it is only relevant for listener
# applications which are compiled with the backlog parameter of the
# liten() call higher than the limit imposed by the kernel. The default
# limit is 5 in Solaris 2.4 and can be routinely bumped up as follows
# ndd -set tcp_conn_req_max <new limit upto 32>
# ndd imposes a max bound on how high this limit can be bumped up since
# it affects kernel memory resource useage and it is not wise to allow it
# to be increased to a dangerous level. This script is to allow experiments
# to increase it to higher values (The unreleased Solaris 2.5 increases
# this limit to 1024 and that should make this script obsolete).
# The exact value chosen should take into account the
# memory available on the machine and how many TCP listeners are likely
# to be affected by this. The known bound that people have been known
# to have experimeted with is 128.
# This script operates by first bumping up the maximum imposed by ndd for
# this parameter using adb on the running kernel image and then using in
# a normal manner to set it to this value.
# To undo its affects, you can use adb to undo what is done here (left
# as an exercise to the reader :-)) or just reboot machine
# Declaring absolute paths here makes the script
# independent of the PATH environment variable
$ECHO "$*" 1>&2
$ECHO "Aborting command" 1>&2
test "$1" = "uid=0(root)" || fail "You must be super user."
if [ $# -ne 1 ]; then
fail "Usage: $progname <limit in decimal>"
set `$UNAME -r`
test "$1" = "5.4" || fail "Only run on SunOS 5.4 (Solaris 2.4)"
if [ $backlog_desired -gt 32 ]; then
$ADB -w -k /dev/ksyms /dev/mem << EOF 2>&1 >/dev/null
$NDD -set /dev/tcp tcp_conn_req_max $backlog_desired