FastCGI Process Control


My VM Pro CentOS 6 server runs quite a lot of web sites, some of which use PHP. I notice a fair number of idle FastCGI processes at any one time that are consuming precious memory. So I’m wondering - can I set a ‘maximum idle time’ for such processes, so that they get automatically shut down when they’re not doing anything? Busy sites would still get the FastCGI benefit, but very quiet sites would not disproportionately hog resources.

Thanks, but…

The only FCGI apache setting that VM Pro seems to set (as far as I can see) is FcgidMaxRequestLen 1073741824 for each VirtualHost.

For FcgidIdleTimeout the default is apparently 300 seconds (once the default of 3 is reached for FcgidMinProcessesPerClass). But that’s not how Apache is behaving! Using Apache Server Status I can see lots of processes that I would have thought “should” have been terminated with these defaults e.g.

Process: php5.fcgi (/home/

Pid Active Idle Accesses State

11171 15461 1399 7 Ready

I guess I’m missing something here? e.g. what FcgidMinProcessesPerClass means?