You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Rob Hartill <ha...@lanl.gov> on 1995/11/20 22:11:43 UTC

[Fwd: Re: SunOs, SOMAXCONN, increase, how?]

I got a response to my SOMAXCONN question that might be of
use to others..

If it works (I might know tomorrow) it'd be worth documenting this.

Mark Thomas wrote:
> 
> Rob Hartill (hartill@lanl.gov) wrote:
> > Given that changing SOMAXCONN in /usr/sys/sys/socket.h
> > seemed to have no affect on our SunOs Sparc 5 running a
> > HTTP server, and that "SOMAXCONN" doesn't seem to be referenced
> > in any of the source files we have to build a new kernel, does
> > anyone know how to or can point me at information that'll
> > let me increase the SOMAXCONN setting?
> 
> I ran into the same problem.  I run a 110 MHz SPARC-5
> clone running 4.1.4, and periodically the web server would
> completely stop accepting connections on port 80 for anywhere from
> several second to several minute periods.  There was a correlation
> between these times, and netstat reporting five or six connections
> persisting in the SYN_RCVD state.
> 
> Increasing SOMAXCONN from 0x5 to 0x42 solved the problem, as now even
> with peaks of 10 to 15 connections in SYN_RCVD, new connections are never
> blocked.  Currently this machine is serving about 300,000
> web connections per day using that harvest cache httpd accelerator;
> performance is great and there are no more stalls.
> 
> SOMAXCONN is compiled into uipc_socket.o by Sun, so the only way
> to change it is to modify uipc_socket.o, then build your kernel.
> 
> My binary mods to uipc_socket.o for sun4m are included below,
> but use them at your own risk.  Also, I am running the uipc_socket.o
> module from patch 102426-03.  I have not noticed any problems, but
> if anyone else does this, I would be interested in hearing about
> your results.
> 
> % od -h /sys/sun4m/OBJ/uipc_socket.o
> 
> before:
>   0000700  d456 2002 9412 a002 d436 2002 8090 0019
>   0000720  3680 0004 80a6 6005 b210 2000 80a6 6005
>                             ^^                  ^^
>   0000740  2680 0004 f236 2020 b210 2005 f236 2020
> 
> after:
>   0000700  d456 2002 9412 a002 d436 2002 8090 0019
>   0000720  3680 0004 80a6 6042 b210 2000 80a6 6042
>                             ^^                  ^^
>   0000740  2680 0004 f236 2020 b210 2005 f236 2020
> 
> -Mark
> 
> --
> Mark G. Thomas (Mark@Misty.com -- http://www.misty.com)