Apache Problems on FreeBSD

Apache Problems on FreeBSD

Post by Michael Wilso » Tue, 21 Jan 1997 04:00:00



We've been having a lot of problems lately with Apache 1.1.1 on FreeBSD
2.1.6-release. The symptoms are that our web server gets slower and
slower over time. We checked the status page and noticed that the more
long running connections we were getting, the slower the server was
getting (see the SS [Seconds since beginning of most recent request]
column below in a sample status page dump below).  Our Time out variable
in httpd.conf is 120 seconds:

 # Timeout: The number of seconds before receives and sends time out
 #  n.b. the compiled default is 1200 (20 minutes !)
 Timeout 120

...so we're not sure why these servers aren't being timed out when they
should be. Notice that the long time SS entries are *not* idle
connections, but are currently in write (W) mode, so the slots are not
available for re-use. Once, out of a possible 50 connections we were
configured to support, 32 of them were in this state, hardly anyone
could connect to us and the site was crawling. This happens repeatedly
and we have to 'kill -HUP' the root httpd daemon at least once a day to
start things over. Then things are flying again. Very strange. In our
kernel we have our SOMAXCONN set to 256 and MBUFF to 4096.

partial status dump:

Srv     PID     Acc     M       CPU     SS      Conn    Child   Slot    Host                            Request
...
9       25148   1/9/264 W       0.20    1831    3.5     0.04    16.16   152.163.237.103         GET
/item.cgi?item=mma0645 HTTP/1.0
10      7367    1/9/540 W       0.09    3720    4.2     0.11    33.02   andona1.cns.hp.com              GET
/pics/ias.gif HTTP/1.0
11      12926   1/9/115 W       0.08    13066   15.4    0.05    0.72    cboi031p12.boi.micron.net
GET /list-1.html HTTP/1.0
12      4834    1/5/5987R       0.06    91      3.7     0.01    36.78
133.san-francisco-005.ca.dial-a GET /about.html HTTP/1.0
...
16      5787    1/2/5505W       0.02    4       15.2    0.01    33.95   p14.gw1.glouc.ma.tiac.com       GET
/pics/new.gif HTTP/1.0
17      17320   1/9/272 W       0.09    12516   0.0     0.09    1.84
102.chicago-035.il.dial-access. GET /pics/power.gif HTTP/1.0
18      25637   1/9/259 W       0.37    8295    0.0     0.08    15.44

 
 
 

Apache Problems on FreeBSD

Post by Marc Slemk » Thu, 23 Jan 1997 04:00:00


Check with ps to see if all the processes listed exist.  If so,
perhaps your server is just too loaded and you need to increase
something like MaxClients to allow for more connections.

If you find a lot that don't exist, then I seem to recall a bug in
1.1.x where child processes sometimes didn't get deleted from the
scoreboard when they died, making the server think that MaxClients
processes were running when many or most of them are just leftover
scoreboard entries.  This is fixed in the 1.2 betas.  For 1.1.x,
turning off DNS lookups should help the problem, and increasing
MaxClients would help a whole lot.


Quote:>We've been having a lot of problems lately with Apache 1.1.1 on FreeBSD
>2.1.6-release. The symptoms are that our web server gets slower and
>slower over time. We checked the status page and noticed that the more
>long running connections we were getting, the slower the server was
>getting (see the SS [Seconds since beginning of most recent request]
>column below in a sample status page dump below).  Our Time out variable
>in httpd.conf is 120 seconds:
> # Timeout: The number of seconds before receives and sends time out
> #  n.b. the compiled default is 1200 (20 minutes !)
> Timeout 120
>...so we're not sure why these servers aren't being timed out when they
>should be. Notice that the long time SS entries are *not* idle
>connections, but are currently in write (W) mode, so the slots are not
>available for re-use. Once, out of a possible 50 connections we were
>configured to support, 32 of them were in this state, hardly anyone
>could connect to us and the site was crawling. This happens repeatedly
>and we have to 'kill -HUP' the root httpd daemon at least once a day to
>start things over. Then things are flying again. Very strange. In our
>kernel we have our SOMAXCONN set to 256 and MBUFF to 4096.
>partial status dump:
>Srv PID     Acc     M       CPU     SS      Conn    Child   Slot    Host                            Request
>...
>9   25148   1/9/264 W       0.20    1831    3.5     0.04    16.16   152.163.237.103         GET


 
 
 

1. Apache Jserv / java servlets under FreeBSD Apache

I dont know if this is really the right place to ask, and I am a
relative Unix novice, but here goes anyway:

We have FreeBSD 2.2.7 and a working install of Apache 1.3.4, compiled with
options --enable-module=most --enable-shared=max. This should enable DSO
support. We also have JDK 1.1.7 ported for FreeBSD, and that works fine
too.

The problem is that I am trying to install java servlet support for apache
with Apache Jserv 1.0b2. I have JSDK2.0 as well, but cant test whether
that "works" OK(!)

The configure script for jserv throws up some peculiar errors: if I ran it
according to the instructions for DSO given on-line,

./configure --with-apache-install="/usr/local/etc/src/apache" \
--enable-apache-conf
(i.e. --with-apache-install=/path/to/apache/source)

then it says "DSO not enabled" and exits.

If I give it the path to my apache installation, it does the same.

The "--enable-apache-conf" seems to make no difference whatever other
options I use.

if I run configure without --with-apache-install, it detects apache in
/usr/local/apache and offers to install it there; it finishes without
error messages whether i answer y or n. But when I "make" (or gmake)
jserv, the make script finishes OK but mod_jserv.so, the essential
library, does not exist anywhere. "make install" (or gmake) also finishes
successfully, however the mod_jserv file is never installed into the
apache libexec directory. Adding the "LoadModule" / "AddModule" things to
httpd.conf stops it from starting correctly.

on further inspection, the makefile in Apache-JServ-1.0b2/src/c
says "cp ./.libs/libjserv.so ./mod_jserv.so" and the .libs diretory does
not exist! This is the only reference to mod_jserv.so anywhere in the
source tree.

Has anyone else managed to install JServ on FreeBSD?

Thanks for your help,
Alan Lawrence

2. 2 NIC's but can only access 1 from outside ! Help needed !

3. Apache 1.3.3 child SIGFAULT problem on FreeBSD 2.2.7

4. Red Hat RPM?

5. Problems with GDBM, PHP/FI and Apache under FreeBSD

6. Question about "boot" command from PROM

7. Problems putting up a Frontpage Web PAge in apache using FreeBSD

8. RCVS and managing multiple development sites info wanted

9. Couldn't spawn child process - Apache webserver problem on FreeBSD system.

10. FreeBSd 2.2.5 - Apache 1.2b10 exec CGI problem

11. Apache compile problems under FreeBSD

12. Apache 1.2.6 on FreeBSD 3.1 access problems

13. Apache under FreeBSD problem