2
Vote

Large File upload into gallery causes crash

description

When I try upload a large image (or several going over a threshold) the system crashes with the following error..
 

Server Error in '/' Application.

 
Maximum request length exceeded.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
 
Exception Details: System.Web.HttpException: Maximum request length exceeded.
 
Source Error:
 
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
 
Stack Trace:
[HttpException (0x80004005): Maximum request length exceeded.]
System.Web.HttpRequest.GetEntireRawContent() +3315778
System.Web.HttpRequest.GetMultipartContent() +56
System.Web.HttpRequest.FillInFormCollection() +222
System.Web.HttpRequest.get_Form() +65
System.Web.HttpRequest.get_HasForm() +3309630
System.Web.UI.Page.GetCollectionBasedOnMethod(Boolean dontReturnNull) +45
System.Web.UI.Page.DeterminePostBackMode() +65

System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +133

Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

comments

AdrianRJ wrote Aug 1, 2009 at 10:01 AM

Oh .. its v.1.3.0 beta BTW !

gvraaij wrote Aug 3, 2009 at 7:58 AM

This problem probably occurs because the default value for the maxRequestLength parameter in the <httpRuntime> section of the Machine.config or Web.Config file is 4096 (4 megabytes). As a result, files that are larger than this value are not uploaded by default. It's not MWPSK related, but ASP.NET.

To resolve this problem, use one of the following methods:

In the Machine.config file, change the maxRequestLength attribute of the <httpRuntime> configuration section to a larger value. This change affects the whole computer.

OR:

In the Web.config file, override the value of maxRequestLength for the application. For example, the following entry in Web.config allows files that are less than or equal to 1 GB to be uploaded:

<httpRuntime maxRequestLength="1048576" />

More info: http://support.microsoft.com/default.aspx?scid=kb;EN-US;295626

AdrianRJ wrote Aug 31, 2009 at 9:09 AM

Many thanks for this ..