views:

14

answers:

1

I changed the maxAllowedContentLength to

<security>
    <requestFiltering>
        <requestLimits maxAllowedContentLength="5024000000" />
    </requestFiltering>
</security>

In my web.config, but when running on IIS7 I get this error:

The 'maxAllowedContentLength' attribute is invalid. Not a valid unsigned integer

http://i.imgur.com/u1ZFe.jpg

but when I run in the VS server it run normally without any errors.

How to config my website to allow upload files with 500MB size, without this problem on IIS7?

+1  A: 

According to MSDN maxAllowedContentLength has type uint, its maximum value is 4,294,967,295 bytes = 3,99 gb

So it should work fine.

See also Request Limits article. Does IIS returns one of this errors when the appropriate section is not configured at all?

abatishchev
so this value i have 5024000000 is by gb?!
Amr ElGarhy
5024000000 > 4294967295
Sam
Yes, what a silly mistake I did
Amr ElGarhy
500MB = 524288000 which is now less than 4294967295
Amr ElGarhy
@Amr: Glad it helped!
abatishchev