Server OS: Windows 2008 SP2
Application: Sharepoint 2007 with SP2
When upload file bigger than 28M to Document Library. IE may have one of the following errors:
"Request timed out" or "HTTP 404"
The result is file failed to upload.
The solution:
Note: This solution is to complete Microsoft KB 925083 (until they can perfect it, also the article is for Sharepoint Services, the central admin part is different on MOSS 2007)
The default Maximum Upload Size in Sharepoint 2007 is 50M, and there's a reason for it.
Microsoft internal setting is set to 100M.
Theoretically, the size can be 2G. Which is the maximum size SQL can handle.
Solution:
1. Launch Sharepoint 3.0 Central Administration, go to "Application Management" -> Under "Sharepoint Web Application Management" section -> click on "Web application general settings"
2. In "Maximum Upload Size", change the default "50"MB to "150"MB, or your maximum file size.
3. Scroll down, in "Web Page Security Validation" section, change "Security validation expires After" from 30 minutes to 120 minutes, or to your maximum time to complete the upload. (Note: if this setting isn't changed, you may get following error when try to upload: "The security validation for this page has timed out. Click Back in your Web browser, refresh the page, and try your operation again." You can already see by increasing this value increases your security risk of been session hijacked)
4. Launch "Internet Information Service (IIS) Manager" on each front end servers, expand IIS server node -> expand Sites -> Find the site that's hosting your Sharepoint site and right click on it -> choose "Manage Web Site" -> choose "Advanced Settings" -> under "Behavior" expand "Connection Limites" -> change "Connection Time-out (seconds)" from 120 seconds to 7200 seconds.
5. On each front end servers, go to "Program Files\Common Files\Microsoft Shared\Web server extensions\12\TEMPLATE\LAYOUTS" folder, make a copy of "web.config" file, then open the file with NotePad, look for following section:
o <location path="upload.aspx">
<system.web>
<httpRuntime maxRequestLength="2097151" />
</system.web>
</location>
o replace it with:
o <location path="upload.aspx">
<system.web>
<httpRuntime executionTimeout="999999" maxRequestLength="2097151" />
</system.web>
</location>
o save the files.
6. On each front end servers, go to "Inetpub\wwwroot\wss\VirtualDirectories\VirtualDirectoryFolder":
o make a copy of "web.config" file, then open the file with NotePad, look for following line:
o <httpRuntime maxRequestLength="51200" />
o replace the line with:
o <httpRuntime executionTimeout="999999" maxRequestLength="51200" />
o Go to very end of the file, right in front of "</configuration>" add following:
o <system.webServer>
<security>
<requestFiltering>
<requestLimits maxAllowedContentLength="157286400"/>
</requestFiltering>
</security>
</system.webServer>
o Note: 157286400=150MB * 1024 *1024. Also if you do not put above code right in front of "</configuration>", but right below "<configuration>" as from the KB, you will get following error:
o Server Error
500 - Internal server error.
There is a problem with the resource you are looking for, and it cannot be displayed.
7. On each front end server, run "Command Prompt" as administrator, then run "iisreset"
Analysis:
There are multiple places has file size and timeout restriction, some of the behaviors are Windows 2008 IIS7 specific (such as the 28M restriction discussed in 942074)
As you can see, changing these value may enable upload bigger files in Sharepoint. However, from the user prospective, when they upload a big file from IE, there's no progress bar indicating the percentage of the upload, and it may take a very long time to upload the file. Users may generally lost patience and click on "OK" button, which only triggers re-upload the same file.
Consider only change these settings when all your users are connected to Sharepoint servers via high speed low latency connections.
Keine Kommentare:
Kommentar veröffentlichen