开发者

Django/Lighttpd stops responding and returns 500 errors

开发者 https://www.devze.com 2023-02-15 05:39 出处:网络
I\'ve got a fairly well behaved web application that has been running fairly stably for a few months, but every once in a we\'ve seen the django application stop responding, and the lighttpd server st

I've got a fairly well behaved web application that has been running fairly stably for a few months, but every once in a we've seen the django application stop responding, and the lighttpd server starts spewing 500 errors.

/var/log/lighttpd/error.log looks like:

2011-03-06 18:20:17: (server.c.1469) server stopped by UID = 0 PID = 32106 
2011-03-06 18:20:18: (log.c.97) server started 
2011-03-08 03:13:12: (mod_fastcgi.c.2494) unexpected end-of-file (perhaps the fastcgi 开发者_如何学Goprocess died): pid: 0 socket: unix:/opt/app/var/app.sock 
2011-03-08 03:13:12: (mod_fastcgi.c.3326) response not received, request sent: 608 on socket: unix:/opt/app/var/app.sock for /app.fcgi , closing connection

And then just the repeated last two lines as far as the eye can see until I restart the django application.

We have the application set up to email us stack traces on 500 errors, which it does, but not when this problem starts.

The fcgi section of lighttpd.conf looks like:

fastcgi.server = (
        "/" + project-name + ".fcgi" => (
                "main" => (
                        "socket" => project-root + "/var/" + project-name + ".sock",
                        "check-local" => "disable",
                        "min-proces" => 4,
                        "max-load-per-proc" => 3,
                        "broken-scriptfilename" => "enable",
                )
        ),
)

Does anyone have any ideas about how to track down what's going on? I suspect we have some issue between lighttpd and our application, or maybe the application does something incorrectly which causes this to occur, but I'm at a loss as to where to look now.


Have you tried putting some debug in the django app to see what the socket is doing on that side? Presumably it does see the requests comming in, but is not responding?

The error you are getting occurs in fcgi_demux_response() - basicaly Lighttpd gets no response ....

0

精彩评论

暂无评论...
验证码 换一张
取 消