mod_fcgid: read data timeout in 31 seconds
I have just noticed in one of the servers managed by me an interesting error.
[error] [client 22.214.171.124] Premature end of script headers: file.php, referer:
At the first look peoples can say that there is a php error but after a closer look i have noticed a warning that explained everything.
[warn] [client 126.96.36.199] mod_fcgid: read data timeout in 31 seconds, referer:
It seems that *default* max_execution_time on php is 30 seconds in php.ini
max_execution_time = 30
Here is a quick fix for this issue :
On webmin/virtualmin :
Login to webmin
Choose domain that has the problem
Increase maximum PHP script run time
modify max_execution_time to a higher value (30 = 30 seconds default) like 60
or disable it with
max_execution_time = 0
save and reload apache
On servers without webmin/virtualmin
modify max_execution_time in /etc/php5/apache2/php.ini with desired value or set 0 for unlimited.
Since this error is generated by mod_fcgid add this setting into your virtualhost or to make it global in fcgid.conf considering that you want to raise timeout value from 30 seconds to 60.