httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Phil Glatz <>
Subject [users@httpd] large number of virtual hosts causing postgres/php to fail with Apache 2.0
Date Sat, 25 Oct 2003 23:58:47 GMT
I recently moved a site from a FreeBSD 4.7 system to a new box with Free 
BSD 5.0; the old site was using Apache 1.3.26 and PHP 4.2.1, the new one 
uses Apache 2.0.47 and PHP 4.3.2 -- both systems run Postgresql 7.3.4.

The server has about 1100 virtual hosts, so on both I increased FD_SETSIZE 
to 2048.  It starts up fine and performs well.  However, when I make a 
pg_connect() call, it fails to load the page, and the syslog indicates 
httpd exited on signal 11.

I created a second Apache installation for another web site on the same 
machine.  All configuration parameters were identical, except I left 
FD_SETSIZE unchanged.  It performs perfectly, connecting to postgres with 
no errors.

I've no other clues as to what the problem may be, and was wondering if 
anyone had any thoughts on the situation.  I researched what I could on the 
number of filehandles issue, and the instructions on 
<> said I 
could "increase the setting of FD_SETSIZE at Apache compilation time by 
adding "-DFD_SETSIZE=nnn" to the EXTRA_CFLAGS line in your Configuration 
file."  I tried doing so by adding "FD_SETSIZE=2048" to the end of my 
command line for configure, nothing was changed.  I also tried tweaking the 
configure script again, to no avail.  Finally, I grepped around and saw one 
place where it was defined in header files (os/unix/os.h_, and added the 
definition there.  Perhaps I didn't cover all the bases?

I like Apache 2.0, but may have to revert to 1.3 if I can't get this 
working.  Since threads aren't natively supported under Free BSD, are there 
other advantages to 2.0 that I might be missing out on?


The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message