View Full Version : File size limit in 5.13
August 18th, 2005, 10:49 AM
We have just moved to a new server and I have upgraded to v5.13. For some reason the upload file size in now limited.
I was made aware of the problem by a user who got a blank screen when he uploaded. So I tried his login. I started with a 37Kb file - OK; then a 96Kb file - OK; then a 195Kb file - blank screen. I tried the 195Kb file with my admin login - blank screen.
This has never happened before. I have checked the settings in Usergroups - no problems there; my settings are all 0 anyway.
The directories /uploads and /data and all sub directories are 777.
Ideas where to go now please.
August 18th, 2005, 11:06 AM
You would either need to get the host to increase the LimitBodyRequest variable to set in usergroup permissions the max filesize variable to a limit so you dont get the php error screen(white screen of death)
August 18th, 2005, 11:08 AM
This is a leased server, where do I make those changes please.
August 18th, 2005, 11:13 AM
In usually your apache configuration file httpd.conf or php.conf
August 18th, 2005, 11:20 AM
Neither of those files have any such setting. I have also used grep to find it, nothing. We have Apache 2.0.52 and PHP 4.3.9. The php.ini file is set a max file upload size of 2M.
August 18th, 2005, 12:03 PM
Do you see anything in the php.conf or httpd.conf file with a file restriction size? It is being limited somewhere here
You can ask your host where your LimitBodyRequest is being set cause it is
August 18th, 2005, 01:10 PM
I tried putting LimitRequestBody 307200 in the php.conf - didn't work, so I tried the http.conf - didn't work. I can upload a file 107Kb but not 109Kb. I cannot find anything that restricts this unless there is a default setting, but I cannot find any reference to a default setting.
August 18th, 2005, 02:58 PM
Can't add anything more than suggest you contact your host as I previously stated
The one setting I know that causes this usually is LimitBodyRequest and there are tons of threads on the internet about this :)
This thread explains all about LimitBodyRequest
Take note after making the proper changes you will need to restart the server and retest.
August 19th, 2005, 04:47 PM
You might try putting this in your .htaccess file in the root of your PP directory
php_value upload_max_filesize 4M
Would change the allowed upload to 4Meg (if your host allows this type modification via .htaccess). Might work... might not... what do I know? :)
August 19th, 2005, 04:52 PM
always worth a try although in my experience only a small percentage of hosts allow php.ini changes through htaccess files in a shared environment.
You will know whether it works right away though ;) as your entire site will be a white page of death if you do this and its not allowed. Then simply get rid of the line if you have a problem and things will be back to normal
August 21st, 2005, 05:39 AM
.htaccess did not work, just got a server error message. This is covered in the Apache 2 docs. The server is not a shared server it is all ours (well, leased)...all of it.
I have in php.ini:
memory_limit = 8M
upload_max_filesixe = 2M
In php.conf I have:
LimitRequestBody 307200 (300K)
I just can't understand why uploading a 195K file is exceeding the memory_limit no matter what I set it at.
August 21st, 2005, 06:52 AM
Well try placing the limitbody in your apache configuration file
Then edit your php.ini make the memory_limit 24mb and you can raise your max upload filesize while your in there if you want
restart your server and test
August 21st, 2005, 12:00 PM
Putting 'LimitRequestBody 307200' in httpd.conf does not work either, as httpd.conf calls php.conf.
I tried your suggestion and changed
memory_limit = 8M
memory_limit = 24M
and it worked for the 195Kb file.
Does this not increase the load on the server ? Why should this memory level be needed?
Thanks for sticking with me on this.
August 21st, 2005, 04:48 PM
Well I have never seen a file size restriction without it being limited with the variable I have already meantioned.
Now that you raised your memory limit what size file can you upload before it does crazy?
Have you tried with Imagemagick as I think your issue is coming from using GD2
August 22nd, 2005, 06:41 AM
240K is the limit at the moment; 324K got a 'page cannot be opened' error. I will need to recompile ImageMagick as it was installed by the ISP when they set up our server so I don't know if it is compiled as per your instructions. It is version 6.2.3
August 22nd, 2005, 08:52 AM
well if you use imagemagick does it work?
August 22nd, 2005, 12:28 PM
No, all I got was the header, background and an empty frame where the photo should be. Is this an IM installation issue? I ran 'make check' before make install and there were a lot of 'FAIL' and 'command not found'.
I have reset it to GD2 and upped the memory_limit = 32M and I was able to upload a 297K file. I have now set a 280K limit on users.
August 22nd, 2005, 01:13 PM
Okay then yes follow our install and you should be able to do an imagemagick install if you dont have root access try doing a non root install
August 22nd, 2005, 02:26 PM
Not sure if the IM install worked correctly, see post #17. I followed your install instructions.
August 22nd, 2005, 02:45 PM
well I cant comment unless you have a specific error message from the install but note in post 18 I stated you can try a non-root install
vBulletin® v3.8.1, Copyright ©2000-2014, Jelsoft Enterprises Ltd.