开发者

Server keeps timing out

I have been trying to extend the timeout session of my server, but it keeps timing out at 30 secs. There is an action that I need to perform that takes longer than that and Im not able to solve this.

I added the set_time_开发者_Python百科limit and max_execution_time to my php.ini file and uploaded it to the root of my site.

set_time_limit = 4500
max_execution_time = 3600

But it doesn't seem to be taking affect, the server keeps timing out at 30 seconds.

I want to set my server time session to 10 minutes. I will lower it, I just need to perform an action. I would really like some help on this. I've be battling this for some days now and can't figure it out.


I added the set_time_limit and max_execution_time to my php.ini file and uploaded it to the root of my site.

That won't do: You either need to edit the central php.ini file (the location of which you can find out through phpinfo()), or set the time limit inside the code using set_time_limit - if PHP is configured to accept individual overrides of the limit.


You say you've added those directives to your php.ini file, uploaded to the root of your site... But is it really this file that's used ?

You can check which .ini file(s) is/are read, by calling the phpinfo() function from one of your scripts.

When you've found which php.ini file is used, you'll have to modify that file ; and, then, you'll probably have to restart Apache, so the modification is taken into account.


As a sidenote : set_time_limit is a PHP function, and not a directive that should be used in php.ini.

Of the two lines your posted, only max_execution_time should be in your php.ini file.


Check your phpinfo() to make sure your php.ini is recognized. You may have to reconfigure your server to accept the php.ini.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜