Modify max_execution_time

I ran the script over at for the custom php.ini and when running phpinfo() it shows “Loaded Configuration File /home/USERNAME/” but whatever values I enter in the php.ini file (mainly max_execution_time), they dont reflect on the phpinfo() page. Is there something that needs to be restarted or refreshed before it will show the new values?

My main issue is a downloading timeout issue where my site offers up a download that is stored outside the webroot to prevent hotlinking and served up by a php script. I have tried set_time_limit(360); in my code but that doesnt seem to do anything so I went the route of doing the custom php.ini install which from my understanding is what I have to do so I can modify the values.

Any suggestions?

I installed sXi’s php.ini mod to increase upload size. After seeing your message, I increased my max_execution_time to 60. It took about an hour (had dinner), but the update finally took hold. I believe it may be a Fast CGI issue where PHP won’t re-read the php.ini file for x amount of time.

That is good to know, thanks… During this time I had searched around on the forums and found this thread It seems that its different for php5 and stumbled my way through and ended up doing this…

[php]$x=cp /dh/cgi-system/php5.cgi ~/;
$y=cp /etc/php5/cgi/php.ini ~/;[/php]

Which copied those into my cgi-bin folder and then put in the .htaccess

AddHandler php-cgi .php Action php-cgi /cgi-bin/php5.cgi

And when I update my php.ini file then it shows the modified values right then. I hope this is ok doing it this way as everything seems fine so far. If anyone sees any issues with this, please let me know.

The sXi scripts are for PHP5. Do you not have FastCGI enabled on your site?

I do have it enabled, but when updating the php.ini wasn’t working with the sXi script then I went looking for other alternatives and this one worked :slight_smile: Not sure why it wasn’t working or if it was delayed and I hadn’t given it enough time. I used this same method on my subdomain and that is working just as good.