[Catalyst] FastCGI Manager, Apache and SIGPIPE

Matt S Trout dbix-class at trout.me.uk
Mon Dec 24 19:04:15 GMT 2007


On Sun, Dec 23, 2007 at 11:35:10PM +0000, Ruben Fonseca wrote:
> hi!
> 
> recently I've put a catalyst website into production using the  
> following config:
> 
> - apache 2 + fastcgi running in external mode
> - 1 fastcgi manager with 2 catalyst childs
> 
> the problem is that randomly, twice a day, the fastcgi manager shuts  
> itself down. the only thing that appears on apache log is "FastCGI:  
> server (pid 8122): safe exit after SIGTERM".
> 
> To dig more, I put the manager, and both the catalyst children under  
> strace and found this:
> 
> - the first child (8121) receives a SIG_PIPE, and shuts down
> 
> 8121  18:17:20 write(4, "\1\6\0\1\26J\6\0\"POST\">\n\t\t\t\t\t<input  
> type"..., 5744) = -1 EPIPE (Broken pipe)
> 8121  18:17:20 --- SIGPIPE (Broken pipe) @ 0 (0) ---
> 
> (probably the client closed the connection earlier? I have no more  
> data on strace about this process 8121, so it really ends here)
> 
> - the manager (8120) sees the child dying (8121) and kills the other  
> child (8122)

I suspect you're running an out of date FCGI::ProcManager; this looks like
you're hitting a bug that's fixed in the latest release.

-- 
      Matt S Trout       Need help with your Catalyst or DBIx::Class project?
   Technical Director                    http://www.shadowcat.co.uk/catalyst/
 Shadowcat Systems Ltd.  Want a managed development or deployment platform?
http://chainsawblues.vox.com/            http://www.shadowcat.co.uk/servers/



More information about the Catalyst mailing list