Error uploading 10MB+ files server returned: HTTP 500

9 posts by 4 authors in: Forums > CMS Builder
Last Post: November 15, 2012   (RSS)

By yodare - November 14, 2012

Has anyone ever received HTTP 500 errors when trying to upload larger files (10-12MB and up) using CMSB admin file upload field (both flash and non-flash) with the following configuration and troubleshooting? . . .

ERROR DISPLAYED in CMSB admin AFTER UPLOAD REACHES 100% (only when trying to upload files 10-12MB or larger):
"Error uploading 'my-14mb-test-file.pdf', server returned: HTTP 500"

SERVER INFO:
Shared Hosting
Linux System running Apache
Default PHP Version 5.2.17

DEFAULT PHP.INI REVISIONS (also added these to php.ini for CMSB directory and custom upload directory):
upload_max_filesize = 100M
post_max_size = 200M
memory_limit = 120M
max_execution_time = 600
max_input_time = 900
;; note... Using default value for upload_tmp_dir

ADDITIONAL NOTES:
CMS Builder v2.15
PHPINFO test displays revised (correct) .ini values
Upload field configured to accept multiple file extensions (including PDF) and unlimited file size
Error when configuring upload field with both custom upload directory and default
CGI Error log shows nothing


[mad] Am I missing something? Should I direct my attention to Apache settings OR to settings within CMSB?

Re: [yodare] Error uploading 10MB+ files server returned: HTTP 500

Hi yodare,

I'm assuming that you have the Maximum upload size in your upload field set to a large enough value or unchecked for unlimited size?

Is it possible that your host has a max ceiling for uploads that you can not override with php.ini?

Jerry Kornbluth
The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php

Re: [yodare] Error uploading 10MB+ files server returned: HTTP 500

By Dave - November 15, 2012

Hi yodare,

It could be a memory limit that is being imposed by the OS. What does the bottom line labeled "Server Resource Limits " say under: Admin > General

If that's not it you can submit a 2nd level support ticket and we'll take a look. Here's a link:
https://www.interactivetools.com/support/email_support_form.php

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Error uploading 10MB+ files server returned: HTTP 500

By yodare - November 15, 2012

For the actual upload field config, I tried both unlimited (box unchecked) and a value of 51200.
Within Admin > General Settings the last line displays the following...
Server Resource Limits: CPU Time: 120 seconds, Memory Limit: 200 MB, Processes: 64306

Is there any chance CMSB is calling PHP Version 5.3 during the upload process instead of my Default PHP Version 5.2? Other than that, the only possible explanation could be Apache settings trumping PHP.INI during execution. Could this happen even when PHPINFO displays my revised/desired values?

Re: [Dave] Error uploading 10MB+ files server returned: HTTP 500

By Codee - November 15, 2012

Just a thought in case the server allows the larger uploads and there's no errors being caught...are you, by chance, testing this with just one file or a variety? If it's just one, is it possible the file is not truly a .jpg file? Maybe open it up in Photoshop or Paint Shop Pro and resave it as a jpeg...and if in Photoshop ensure the "web friendly" jpeg is chosen.

Re: [Dave] Error uploading 10MB+ files server returned: HTTP 500

By yodare - November 15, 2012

Thanks for test file Dave. I put it in the CMSB directory and tested it with a 5MB file and a 14MB file. The 5MB file displayed successful upload results. The 14MB file displayed a 500 Error page.

I called the web host tech support and they mentioned PHP had a 32MB limit (which is BS). The tech support guy put me on hold... 5 min later he said I now have a 32MB limit. HOWEVER... before I hung up the phone, I refreshed my phpinfo test page and it served me an ERROR PAGE! In fact, all php pages within the CMSB directory served up the same ERROR. He stuttered for awhile after I informed him of the directory error, then he said... a ticket was created and sent up a few tiers. [crazy]

Well... I looked into the new issue and it appears the Default PHP Version was changed to v5.3 by Tech Support. I set the Default PHP Version back to 5.2 and my php pages started loading again. v5.3 could have conflicted with directive php.ini values in CMSB directory. Anyway... I'm still waiting to hear back from a more knowledgeable hosting tech support rep. I'll let you know what I discover.

Re: [equinox69] Error uploading 10MB+ files server returned: HTTP 500

By yodare - November 15, 2012

That's a good point equinox69, but unfortunately, it was one of the first things I tried. File dimensions, color-space, unknown extensions, and file corruption can always have the potential for generating upload errors. I tested a handful of different files/file-types; all which produced the same error.

Re: [yodare] Error uploading 10MB+ files server returned: HTTP 500

By Dave - November 15, 2012

Ok sounds, good.

If they cause problems, you can remove the .htaccess and php.ini in the /cmsAdmin/ folder. They're just there to try and "normalize" the php environment and aren't supported by all servers anyways.

What we've found, is that sometimes it's best to just present the problem to the host and see if they can fix it. You might point them to the demo upload script and ask if it's possible to upload files larger than 10 megs on their server via PHP. The test script doesn't contain any program code at all, so if it doesn't work, it's a clear indication the server has limits or issues.

Let me know how it goes.
Dave Edis - Senior Developer
interactivetools.com