Check http://www.acme.com/software/thttpd/benchmarks.html and look
at the graph at the bottom.  There is a discussion of sending http
headers out separate from the data, which is (I believe) what AOLServer
does.  This throttles performance because of TCP/IP "slow start" and
the TCP/IP Nagle.

There is a feature on Linux called TCP_CORK, or something like that,
that tells TCP/IP to not send out partial packets.  This lets you
do multiple writes without triggering tcp's "slow start".

The other suggestion I've seen is to do writev and write the header
and data buffers in one call to avoid the same problem.  This may
affect the Ns_ API to some degree and might take more effort to
implement transparently.

I haven't done the thttpd benchmarks with AS, so don't know for sure
that it suffers from the same problem.

Jim

>
> In a message dated 3/31/2001 1:03:13 AM Eastern Daylight Time,
> [EMAIL PROTECTED] writes:
>
>
> > I've been trying to tune AOLServer for performance with static pages.
> > The things I've done is to turn of logging,set threadmax to 20 and 1
> > connection per thread
> > Is it possible to get AOLServer to outperform Apache with static pages (the
> > Apache server is tuned)?
> >
> > The benchmarks were currently seeing is about 1000 pages/s with AOLServer
> > and 2000 pages/s with Apache
> >
> > I'm currently running a E420R with two CPU's and Solaris 2.7.
>
>
>
> Turns out connsperthread is ignored.  When it wasn't ignored you'd want it at
> 0, i.e., infinite to avoid creating new threads all the time.
>
> You might be able to tweak some of the socket driver config as well, perhaps
> "backlog", and "sndbuf", and "rcvbuf" options (check the code in
> nssock/sock.cpp).
>
> Otherwise, AOLserver is designed for dynamic page performance and
> programmability at the expense of some performance optimizations.  For
> example, the I/O isn't as efficient as it could be, done directly by the conn
> threads under the assumption the time to generate the page (i.e., the ADP or
> Tcl script) dominates.  The fastest static servers are generally
> single-threaded, event driver designs.  We could probably tune the aolserver
> for static pages but I'm not sure we'd get far without breaking the API,
> e.g., by bypassing all the filters and traces (logging) and such and handling
> the connection entirely in the socket driver.
>
> -Jim
>

Reply via email to