ASP.net Upload Limit Server timeout

删除回忆录丶 提交于 2019-12-08 07:18:56

问题


I'm having a problem with uploading files in the media section of Umbraco. I'm not sure if the problem is size related as I don’t get an error that give too much details but I'll explain what I’ve done so far and see if you can help.

I've added:

<httpRuntime maxRequestLength="102400" executionTimeout="3600"/>

to the web.config within the tag

I've added the same httpRuntime tag to the servers default web.config restarted all the app pools for the websites and the problems still persists.

The error I receive when I try to upload files is:

Explanation: The request timed out before the page could be retrieved. Technical Information (for support personnel)

* Error Code 64: Host not available
* Background: The gateway or proxy server lost connection to the Web server.
* Date: 10/8/2009 4:27:46 PM
* Server: SERVER.XXXXX
* Source: Remote server 

The odd thing about the problem is that it does not only happen on files over the magic 4mb file size. It seems to happen on any files uploaded above about 1mb.

Any help much appreciated.


回答1:


Are you using IIS 7 with integrated pipeline perhaps? If so, you may need to add some settings to your system.webserver section:

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

You need this in addition to your httpRuntime settings.




回答2:


It turns out it was not to do with the Web.config or the metabase.xml.

The problem was that the AppPool for the website had a virtual memory limit that was too low and I guess the site Pool was being recycled before the file had finished uploading.

For the time being I've removed the limit. I'll need to read up before setting it again.




回答3:


Read this: link

It seems server 2008 has a known error on this (IIS7 has a max. upload restriction you have to manually edit via the web.config of the specific web app

I'm currently working on this fix, locally now the upload works (respecting the set max. upload limit), except via Internet (passed the ISA) it still doesn't.

I'm trying to figure out if I also have to edit the WFE's to make it work via the Internet, but not sure if this fixed my problem or has anything to do with it.

  • Roberto


来源:https://stackoverflow.com/questions/1539152/asp-net-upload-limit-server-timeout

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!