Welcome! Log In Create A New Profile

Advanced

Re: request hangs

agentzh
February 28, 2011 02:54AM
On Mon, Feb 28, 2011 at 2:33 PM, magz <nginx-forum@nginx.us> wrote:
> magz Wrote:
> -------------------------------------------------------
>> Hi,
>>
>> I have strange problem with main request  hand if
>> I call for sub-request.  Maybe somebody can help
>> me with it?
>>

Which version of nginx are you using?

If you're using nginx 0.8.x and above, the symptom suggests you didn't
get r->main->count right. Use --with-debug while building your nginx,
and track the values of r->main->count.

For example, in the following line of my local error.log,

2011/01/28 13:01:50 [debug] 1199#0: *1 http finalize request: -4,
"/main?" a:0, c:3

a:0 means the current request is not the active request at the moment
(i.e., r != r->connection->data), and c:3 means r->main->count is 3.
The request can only be successfully finalized unless it is the
current active request. Also, the main request won't terminate, i.e.,
will hang if the r->main->count counter is not going to be decremented
to zero. Well, r->main->count is just a reference counter for the main
request object. A simple way of doing poors' "garbage collection",
well, at least kind of.

When doing subrequest programming on the C level, one should be VERY
VERY careful with these two values, among other things :)

Cheers,
-agentzh

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

request hangs

magz February 25, 2011 08:27PM

Re: request hangs

magz February 28, 2011 01:33AM

Re: request hangs

agentzh February 28, 2011 02:54AM

Re: request hangs

magz February 28, 2011 03:23AM

Re: request hangs

magz February 28, 2011 01:26PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 177
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready