On 8/19/2009 8:07 PM, Corey Edwards wrote: > Kenneth Burgener wrote: > >> The overhead is due because when building a "new" connection there is a >> lot of hurdles to pass: >> > And since he's specifically talking about HTTPS, the encryption overhead > gets even worse. I'm not surprised at all to hear that keep-alive sped > up the server by that much. > > Corey >
True true. And a follow up to my comments... Here is straight from the apache docs: "provide long-lived HTTP sessions which allow multiple requests to be sent over the same TCP connection. In some cases this has been shown to result in an almost 50% speedup in latency times for HTML documents with many images" [1] Yes, that is 50% improvement, quoted from the apache documents. And the reason that the KeepAlive is turned off by default is: "Each time a keep alive session is open and the client does not use it, Apache will still keep the server process/thread busy and thus it won't be able to accept another connection on that server - which will limit the throughput." The solution to this problem is to either turn off KeepAlive or set tight other restrictions such as MaxKeepAliveRequests and KeepAliveTimeout (2-15 seconds is reasonable). It is highly recommended to set the MaxKeepAliveRequests/KeepAliveTimeout to reasonable numbers so that, "A limit is imposed to prevent a client from hogging your server resources." [1] Kenneth [1] http://httpd.apache.org/docs/1.3/mod/core.html#keepalive /* PLUG: http://plug.org, #utah on irc.freenode.net Unsubscribe: http://plug.org/mailman/options/plug Don't fear the penguin. */
