Forum Moderators: phranque

Message Too Old, No Replies

apache file upload limits

         

bbxrider

6:23 pm on Oct 27, 2008 (gmt 0)

10+ Year Member



running apache 2.2.4, php5 as apache module, not cgi, under win xp pro, its my personal dev machine/environment, so i have complete provisioning control
trying to build up a php large file upload application, possible 10gb video files
have all the php settings way up, (just to get a base starting point, and proof of concept thing) 20000m post and max file size, 3600 secs for time limits, only 128m memory, but i only have 1gb chip mem, so i could never really set that to say something like 4gb, all checked with phpinfo(), 10g on the form limit (<input type="hidden" name="sizelimit" value="10000000000" />)
but when trying to test up load a 1gb+ file, getting stopped at 500mb, see following php message
Warning: POST Content-Length of 1345788422 bytes exceeds the limit of 545259520 bytes in Unknown on line 0
some php folks think its somewhere in my apache, i haven't seen any apache directives in my .conf that would seem to do that? right now there no 'limitRequest*' directives in my .conf
can anybody think of something i'm missing with the apache? or apache working with php? or ?
bob

jdMorgan

8:46 pm on Oct 27, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Setting LimitRequestBody to zero will make the content-body size unlimited. Otherwise, the maximum limit which can be explicitly set is 2147483647 bytes (2GB). Note that 1 GB is not a power of ten, but a power of 2.

Think in terms of "chunks" of 1024 or 2^10th, for example, not in chunks of 1000 or 10^3rd.

Interestingly, when speaking of kilobytes or kilobits per second transmission rates ("bandwidth"), multiples of 1000 *are* generally used -- But this is probably because ISPs and Webhosts are more marketing-promotion-oriented than memory and server manufacturers: They sell a little less for a little more... :)

Jim

bbxrider

6:39 am on Oct 28, 2008 (gmt 0)

10+ Year Member



thanks jd
turns out the php.ini settings for upload_max_file and post_max_size need just the right syntax
10G works
10000000000 works
10000M does not work
10000m does not work

i never had the limitRequestBody directive in my .conf, so it was never a problem i guess, because of its default to 0 for unlimited