[pmwiki-users] need help making big uploads work
Patrick R. Michaud
pmichaud at pobox.com
Wed Feb 23 09:31:48 CST 2005
On Wed, Feb 23, 2005 at 10:14:18AM -0500, Neil Herber wrote:
> On one of my PmWIki installations I have enabled large uploads. The site is
> password protected and all of the authorized users are trusted so there is
> no concern about hackers or malware uploads.
>
> It took me a fair bit of time to find all of the bottlenecks that prevent
> large uploads:
> 1) The $UploadExtSize limit in PmWiki
> 2) The upload_max_filesize, post_max_size, and memory_limit in php.ini
> 3) The LimitRequestBody in the Apache conf file
>
> But I have those all set appropriately large, and uploads work just fine
> from the LAN, but not from the WAN.
> The problem is a PHP timeout that generates this error:
> PHP Fatal error: Maximum execution time of 30 seconds exceeded
> I presume that this is a php.ini setting that I could bump up if I chose
> to, but:
> 1) What is the downside of raising the time limit?
> 2) Is there a more robust method I can use for uploading large files?
Interesting, I'm surprised that PHP watches time limits on uploads.
However, I don't think there's any real downside to raising the time
limits. Try
ini_set('max_execution_time', '300');
ini_set('max_input_time', '300');
in config.php and see if it allows larger uploads. You may be able
to raise the time limit just for uploads via:
if ($action == 'postupload') {
ini_set('max_execution_time', '300');
ini_set('max_input_time', '300');
}
If these don't work, you may need to change the settings in a PHP
initialization file somewhere.
Pm
More information about the pmwiki-users
mailing list