asp.net文件上载在加载页面时重置了与服务器的连接

Abh*_*bhi 4 asp.net large-file-upload

当我尝试上传32MB的文件时,firefox在页面上显示以下错误.

"连接已重置.页面加载时重置了与服务器的连接."

我试过了foll.方案 -

1.在<system.web>

<httpRuntime maxRequestLength="2000000000" executionTimeout="999999"/>
Run Code Online (Sandbox Code Playgroud)

2.在<system.webserver>

 <security>
  <requestFiltering>
          <requestLimits maxAllowedContentLength="2000000000" />
  </requestFiltering>
 </security>
Run Code Online (Sandbox Code Playgroud)

<compilation defaultLanguage="c#" debug="false" />
Run Code Online (Sandbox Code Playgroud)

但仍然得到同样的错误.我认为问题与"executionTimeout"有关.应用程序未为请求设置此超时.

Abh*_*bhi 6

最后解决了问题......我们需要在配置文件中保留两个标签.即

<httpRuntime maxRequestLength="2000000000" executionTimeout="999999"/>
Run Code Online (Sandbox Code Playgroud)

<security>
    <requestFiltering>
        <requestLimits maxAllowedContentLength="2000000000" />
    </requestFiltering>
</security>
Run Code Online (Sandbox Code Playgroud)

实际上我正在评论一行并用另一行进行测试.:)