we're running centos/cPanel on a good size dedicated server with only one website. we need speed and ability to upload files under 'nobody'. that means suPHP and DSO are out. so the php handler is mod_fcgid. from time to time apache error logs will show mod_fcgid: read data timeout in 40 seconds. we assume it means mod_fcgid is not properly configured when installed using easyapache.
after reading up on g about how to fix we found two tidbits. one deals with MPM. the other, surprisingly, shows how to increase the timeout response (normally increasing timeout response is bad thing as there is something worse inside the server).
should we use MPM event, prefork, and/or worker with mod_fcgid? we currently have prefork configured.
if we do increase the timeout should we use the following settings:
IPCConnectTimeout 20
ProcessLifeTime 120
IdleTimeout 60
IdleScanInterval 30
MaxRequestsPerProcess 499
MaxProcessCount 100
OR
FcgidProcessLifeTime 8200
FcgidIOTimeout 8200
FcgidConnectTimeout 400
FcgidMaxRequestLen 1000000000
And if we do use either of these settings where should they be set: 1) in php.fcgi script, or 2) FastCGI configuration in Apache.
My tested solution, same issue
target config file :
/usr/local/apache/conf/includes/pre_virtualhost_global.conf
target value :
FcgidIOTimeout
applying changes :
/scripts/rebuildhttpdconf
/etc/init.d/httpd restart
reference : https://wiki.mikejung.biz/Fcgid#FcgidMaxRequestLen