Connection interrupted while uploading large files in browser (.NET application)

I have a website which allows users to upload large video files. Some of these files can be over 50MBs.

I've updated the web.config file to allow for files up to 2GB to upload (and run for 60 minutes):
<httpRuntime maxRequestLength="2048000" executionTimeout= "3600"  />

I can upload a 20MB file but when I try uploading an 80MB file, the browser times out and displays this error:

Connection Interrupted
The connection to the server was reset while the page was loading.
The network link was interrupted while negotiating a connection. Please try again.

What else can i do to ensure that the connection will be interrupted? Are there changes in IIS that can be applied? To the server itself (Windows Server 2003 / SQL Server 2005)?


Who is Participating?
Some Custom Upload modules that u can use

Also try using
<httpRuntime maxRequestLength="2048000"  />

let us know what is the outcome. Also if you can keep track of how much data was uploaded and after how long the error occurred. this can point to where you should be looking into to solve it
in your webconfig increase your connection timeout.
bearclaws75Author Commented:
I updated my web.config (and machine.config) to use the following settings:

      <httpRuntime executionTimeout="7200" maxRequestLength="2048000"
      minFreeThreads="8" minLocalRequestFreeThreads="4"
      appRequestQueueLimit="100" />

In IIS, I set the "connection timeout" value to "7200".

Now, I receive a new error. This error is actually a .NET error (not a browser error).

It states that the maximum request length has been exceeded, however, the maxRequestLength is set to 2GB and the file I am uploading is only 50MB.

Any ideas?

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

Open in new window

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

if you are using cookieless session then use

useFullyQualifiedRedirectUrl = "True"

another thing i would suggest is look into IIS Log File to see the exact error. also if you can catch the error in the application then you will know exactly whats happening
bearclaws75Author Commented:
We were unable to fix this via the server or application configuration settings. We decided to you an existing 3rd party uploader to resolve this issue.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.