【问题标题】:website not allowing large file uploads网站不允许上传大文件
【发布时间】:2012-04-23 14:08:01
【问题描述】:

我有一个在 IIS 6 上运行且运行良好的 ASP.NET 网站。我们允许我们的客户毫无问题地上传大文件 (50MB+)。我们最近搬了家(我的公司),我们的网站也搬到了异地(在我们自己大楼的服务器上之前),我们不得不从 IIS 6 切换到 IIS 7。自从搬家后,我们的网站赢了'不允许我们的客户传输大文件。我已经测试过较小的文件(

404 - File or directory not found. The resource you are looking for might have been removed, had its name changed, or is temporarily unavailable.

我们的 web.config 中已经包含以下内容:

<httpRuntime maxRequestLength="1321600" />

IIS 7 中是否有我遗漏的设置?

【问题讨论】:

标签: asp.net iis iis-7


【解决方案1】:

您应该能够从 web.config 更改此设置:

<system.webServer>
        <security>
            <requestFiltering>
                <requestLimits maxAllowedContentLength="524288000"/>
            </requestFiltering>
        </security>
</system.webServer>

更多信息在这里:http://support.microsoft.com/kb/942074/

【讨论】:

  • 嗨 Bobek,Mb 中的“524288000”与什么有关?
【解决方案2】:

上传限制存储在您的 machine.config 中。

您可以像这样在 web.config 中覆盖它:

<system.web>
        <httpRuntime executionTimeout="110" maxRequestLength="20000" />
</system.web>

你可以在this MSDN document找到更多信息。

【讨论】:

  • 我们的 web.config 中已经有这个了....对不起,我打算把这个放在我原来的帖子里但忘了。
  • 在这种情况下,bobek 的答案可能就是您想要的。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2022-01-19
  • 1970-01-01
  • 2014-02-19
  • 2016-01-07
相关资源
最近更新 更多