List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:June 21 2000 5:58pm
Subject:Re: php and persistent connections
View as plain text  
At 10:25 AM -0700 2000-06-21, Michael  Tanoviceanu wrote:
>Hi all,
>
>Question regarding using persistent connections via php: I have been
>observing the server connections via 'show processlist', and it appears as
>if our persistent connections are closing earlier than the value in
>wait_timeout (8 hours).  Has anyone else seen this?  Is there a true
>advantage in using persistent connections via standard ones that close at
>the end of the script?  Also, is there a general rule of thumb regarding
>memory requirements per open connection?  Any suggestions to how to gage the
>maximum amount of connections allowed via max_connections?

A persistent connection will not live past the life of the Web server process
that opens the connection.  If you're using Apache, for example, each child
process handles the number of requests defined by the MaxKeepAliveRequests
parameter. For example, in my httpd.conf, I have this:


# MaxKeepAliveRequests: The maximum number of requests to allow
# during a persistent connection. Set to 0 to allow an unlimited amount.
# We recommend you leave this number high, for maximum performance.
#
MaxKeepAliveRequests 100


This might explain what you're seeing.

-- 
Paul DuBois, paul@stripped
Thread
php and persistent connectionsMichael Tanoviceanu21 Jun
  • Re: php and persistent connectionsPaul DuBois21 Jun
  • Re: php and persistent connectionsGuillaume Giroux21 Jun