httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Kew <>
Subject Re: [users@httpd] Restricting mod-dbd by location
Date Fri, 09 Mar 2012 19:20:17 GMT
On Fri, 09 Mar 2012 16:37:44 +0000
Alex Bligh <> wrote:

> However, I /think/ it means that there is one connection per
> worker in a non-threaded environment still?

In a non-threaded environment, your choices are the two classic/
ancient models: original CGI (one connection per hit) and original
LAMP (one persistent connection per process).

> if I have (say) 100 mpm-prefork workers, and 0.001%
> of my queries are to the <Location> concerned (this ratio is approximately
> correct numerically), I don't really want 100 database connections
> constantly open, lasting for the life of the mpm-prefork worker.

Then you want the classic-CGI-style setup.  DBD will give you that
with min=0, max=1, and no keepalive on the connections.

Most people don't want that setup, because opening and closing
database connections is too much overhead.  But with prefork and
your numbers it makes sense.  Though a threaded MPM and a small
number of persistent connections would be ideal!

> Or can it pool connections between mpm-prefork workers?


Nick Kew

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message