Phantom event for closed and removed socket

Igor Sysoev is at rambler-co.ru
Thu Nov 29 10:27:01 MSK 2007


On Wed, Nov 28, 2007 at 08:04:13PM -0600, Andrew Deason wrote:

> I'm running nginx 0.5.32 on a box running Solaris 10u3 as a
> load-balancing reverse proxy. We're seeing a lot of these messages in
> nginx-error.log:
> 
> 2007/11/28 19:37:15 [alert] 27779#0: phantom event 0001 for closed and
> removed socket 106
> 2007/11/28 19:37:16 [alert] 27779#0: phantom event 0001 for closed and
> removed socket 141
> 2007/11/28 19:37:16 [alert] 27779#0: phantom event 0004 for closed and
> removed socket 81
> 2007/11/28 19:37:16 [alert] 27779#0: phantom event 0001 for closed and
> removed socket 112
> 
> There's usually a lot of them like that in a row, but they are short
> bursts, with a longer time between bursts (between a few minutes or an
> hour). What does this mean? Is it a real problem, and what can I do to
> fix it? We're not experiencing any serious problems; occaisionally the
> server will not respond to a request, but that may be an unrelated
> networking issue we're looking at.
> 
> I found this: http://www.lexa.ru/nginx-ru/msg12678.html , but I cannot
> read Russian, and I don't trust myself to guess at what that means.
> Since it was provided there, so I need to provide debug info for this?
> 
> I tried switching to the eventport module when I saw that this message
> is generated by the /dev/poll module, but that had problems with
> requests originating from the same host as the server, so that's not an
> option for us.

This is inconsistency in nginx /dev/poll processing.
/dev/poll returns several events for one iteration, and while processing
one of events nginx closes socket of another event: for example, a client
has closed connection so nginx closes proxy/fastcgi connection for this
request and so. In general, nginx should silently discards these events
and I will probably do so.

To ensure that this is nginx processing effects you may try to set

events {
     devpoll_events  1;
}

and /dev/poll will return the single event per iteration.
I do not think that will decrease perfomance noticeably.


-- 
Igor Sysoev
http://sysoev.ru/en/





More information about the nginx mailing list