httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralf S. Engelschall" <>
Subject Re: Apache/pthread and locking problem
Date Wed, 11 Aug 1999 14:59:29 GMT

In article <> you wrote:

> [...]
> When a connection is established the worker threads start working. When I push
> in the request to the socket immediately I get the response (for instance via
> ab or `echo | socket', etc.).  But when I enter the request on the socket
> manually, the worker thread usually gets a -1 from read() and does a select()
> until data is actually available. Now comes the problem: While the worker
> thread is waiting, the thread which does the socket accepts starts over with
> his loop and does the accept_mutex_on again. And now the whole process stops
> until a new connection comes in. Until then the whole process is suspended
> because both flock() and fcntl() based mutexes do suspend the whole process
> and not just the current thread. At least that's the case for flock and fcntl
> with both FreeBSD uthread and GNU Pth.
> [...]
> Hmmm... either my understanding of the hybrid process model is still not quite
> correct, or I've overlooked an important part, or I'm right and the stuff
> cannot work with the standard user-space threading environments :-( Please
> prove me to be wrong!

Hmmm... seems like I'm right: When I remove the accept_mutex_on/off calls the
servers no longer hangs on connections (this was with Apache-mpm-dexter)...

                                       Ralf S. Engelschall

View raw message