N
N
NikoB2011-06-10 04:40:32
FastCGI
NikoB, 2011-06-10 04:40:32

[apache2 + fastcgi] How to increase timeout time (for long running scripts)?

The Apache2 + FastCGI bundle is used
How to increase the timeout for scripts that run for a long time (let's say a day) so that the error 500 does not fall out.
max_execution_time in php.ini does not help
IPCConnectTimeout 3600
IPCCommTimeout 3600
in /etc/apache2/mods_available/fcgid.conf doesn't help either.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
mrsender, 2011-06-10
@mrspender

This problem also infuriated me, for myself I even thought about some kind of technical problem in the communication between apache and my script.
As a result, I scored and launched it through mod_php - it works stably.

J
Juggler, 2011-06-10
@Juggler

If there is NGINX, the timeouts must be increased there as well.

@
@sledopit, 2011-06-10
_

In Apache, you can write something like this: And they rightly said about launching by cron, unless, of course, these are your single scripts.
<IfModule mod_fcgid.c>
FCGIWrapper /path/to/data/php-bin/php .php
FcgidMaxProcessesPerClass 3
AddHandler fcgid-script .php
FcgidConnectTimeout 360
FcgidIdleTimeout 360

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question