ihmar
ihmar

Reputation: 21

Large files upload

I have a form with 5 asp.net upload controls. This is to allows user to upload 5 large files and submit. What would be the required steps to be able to achieve this? I have checked following configuration in IIS, Application Pool: Idle Timeout: 20min, Recyclicing regular time interval: 1740 min. I've specified following in my web config file,

  <system.web>
    <httpRuntime maxRequestLength="1048576" requestValidationMode="2.0"/>
  </system.web>
  <system.webServer>
    <security>
      <requestFiltering>
        <requestLimits maxAllowedContentLength="1073741824"/>
      </requestFiltering>
    </security>
  </system.webServer>

I am not able to to upload files when I try to upload files in all 5 upload controls.

Upvotes: 1

Views: 1174

Answers (1)

Blachshma
Blachshma

Reputation: 17385

There are a few reasons that may cause this, it's hard to know which without you letting us know which error you receive.

First: Notice that maxRequestLength is in KB whereas maxAllowedContentLength is in bytes. Try increasing maxRequestLength like so: maxRequestLength="2000000000"

Second: Try a higher execution time such as executionTimeout="999999"

<httpRuntime maxRequestLength="2000000000" executionTimeout="999999"/>

Your current setup of maxAllowedContentLength allows 1024 MB. Make sure it isn't lower then the total size of all 5 files.

Upvotes: 1

Related Questions