I’ve made a FastCGI application which, on the face of it, works well:
it’s fast, responsive, and reasonably light on the processors.
However, at seemingly random intervals (usually a few hours apart), it
just stops responding; a (graceful) restart of Apache can bring it
back to life.
Software versions are:
Fedora Core 4 i386
Ruby 1.8.2 or 1.8.3 (both exhibit the same problem)
Before a failure occurs, the httpd error log contains a lot of messages
FastCGI: incomplete headers (0 bytes) received from server
“/…/foo.fcgi”, referer: …
FastCGI: comm with (dynamic) server “/…/foo.fcgi” aborted: (first
read) idle timeout (60 sec), referer: …
After a failure, many stale fcgi handler scripts remain in the process
table. They can’t be killed without using SIGKILL.
I’d be very grateful for any pointers in debugging this: things I
should look at, and things I could try. Combinations of FastCGI
parameters that work for you would be really helpful, too. The
application handles around 80,000 requests per day, and the hardware
really should be adequate (Quad Xeon 2.4 GHz).
Any useful suggestions will be gladly received!