Put this in your event...
Page.ClientScript.RegisterStartUpScript(this.GetType(),"close","<script language=javascript>window.opener.location.reload(true);self.close();</script>");
A sounding board for my thoughts, my interests and my life. I like to think of it as therapy.
Monday, August 29, 2011
Did my first session with counselor
I finally went to see a counselor for my addiction. Actually, I've been to a counselor before, but due to my own stubbornness would not continue to go. And that was like 4 years ago and I just kept feeding the addiction off and on promising myself that this would be the last time. Anyway, I think things are going to work out better this time. We had a good conversation of about an hour. A lot of things have come back to mind just in the short time we talked. For a while I've always wanted to deny that this problem started at a young age with me, but I guess it has. Even as a young child exposed to pornography it can cause permanent damage. When I say young I would say I was about eight years old. I guess it's not too hard to understand given how early childhood abuse can often manifest into the abused becoming the abuser at a later age. I'm feeling good about things right now, so I want to just keep it going. I'll check back in later.
Tuesday, August 23, 2011
“Request timed out” or “HTTP 404″ error when try to upload big files to Sharepoint 2007 Server
Example Scenario:
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: Ask your user to shrink the files they wanted to upload (eg. powerpoint files that contains high resolution pictures), or split the file to files smaller than 50M, if possible.
Solution 2: (take a deep breath)
Find out what’s the absolute maximum file size you need. Eg: let’s say 150M
Find out what’s the maximum time it will take, from your slowest satellite office that need to upload this 150M file to Sharepoint server (via ftp). In my case, it’s 2 hours…
(Note: A solution has been found for the extrem slow upload, see my post: It takes a long time to upload big files to Sharepoint Document Library via WAN)
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.
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: Ask your user to shrink the files they wanted to upload (eg. powerpoint files that contains high resolution pictures), or split the file to files smaller than 50M, if possible.
Solution 2: (take a deep breath)
Find out what’s the absolute maximum file size you need. Eg: let’s say 150M
Find out what’s the maximum time it will take, from your slowest satellite office that need to upload this 150M file to Sharepoint server (via ftp). In my case, it’s 2 hours…
(Note: A solution has been found for the extrem slow upload, see my post: It takes a long time to upload big files to Sharepoint Document Library via WAN)
- Launch Sharepoint 3.0 Central Administration, go to “Application Management” -> Under “Sharepoint Web Application Management” section -> click on “Web application general settings”
- In “Maximum Upload Size”, change the default “50″MB to “150″MB, or your maximum file size.
- 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)
- 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.
- 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:
- <location path=”upload.aspx”>
<system.web>
<httpRuntime maxRequestLength=”2097151″ />
</system.web>
</location> - replace it with:
- <location path=”upload.aspx”>
<system.web>
<httpRuntime executionTimeout=”999999″ maxRequestLength=”2097151″ />
</system.web>
</location> - save the files.
- <location path=”upload.aspx”>
- On each front end servers, go to “Inetpub\wwwroot\wss\VirtualDirectories\VirtualDirectoryFolder”:
- make a copy of “web.config” file, then open the file with NotePad, look for following line:
- <httpRuntime maxRequestLength=”51200″ />
- replace the line with:
- <httpRuntime executionTimeout=”999999″ maxRequestLength=”51200″ />
- Go to very end of the file, right in front of “</configuration>” add following:
- <system.webServer>
<security>
<requestFiltering>
<requestLimits maxAllowedContentLength=”157286400″/>
</requestFiltering>
</security>
</system.webServer> - 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:
- Server Error
500 – Internal server error.
There is a problem with the resource you are looking for, and it cannot be displayed.
- On each front end server, run “Command Prompt” as administrator, then run “iisreset”
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.
First post!!
Well, this is my journal. My escape. My place to just put it all out there and just get stuff off my mind. A lot of stuff goes on during the day and throughout life and sometimes we don't have time to capture it all and remember it the way it actually happened. I'd like to use this blog as a repository for my passions...my God, my family, cooking, reading, exercise, tech gadgets, and various aspects of software development. I'd also like to sound off about my struggles, my challenges and my weaknesses. A lot of like to think we're so strong of mind, but you'd be amazed at how some of the small things can bring us to our knees. I've battled with sexual integrity for much of my life and you'll see me discuss it here.
Subscribe to:
Comments (Atom)