Sitecore Update Package Timeout Issues

It’s been a little while since my last blog post as my Baby Daughter Char(Charlotte-Sienna) arrived 2 months ago which has made it a bit challenging to find time to write some. This seems to have happened to a bunch of Sitecore developers I know and it’s took me a while to get back to it.

I don’t have a Sitecore T-Shirt for her yet so given the lack of pictures in this blog post here’s one of her in an England shirt from back at the World Cup. It didn’t help, we still lost…

 

Update Package Woes

I recently had to upgrade a local Sitecore 8.2 update 6 instance to 8.2 update 7 using the Sitecore Update Installation Wizard and ran across a timeout issue which was as follows:

‘Sitecore.Shell.Upgrades.PostStep,Sitecore.Client’
Error executing post step (Sitecore.Shell.Upgrades.Bug118164PostStep): System.Data.SqlClient.SqlException (0x80131904): Execution Timeout Expired. The timeout period elapsed prior to completion of the operation or the server is not responding. —> System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) …

There was more to the error but you get the idea. It looked like an issue with SQL Timeouts. I wasn’t sure why as on my local machine (with a local database) connections should be pretty quick.


TL;DR

Close all other programs / browser tabs to free up RAM & Processing power, make some config changes and add the patch file at the bottom of this post to Sitecore (Temporarily – delete it afterwards) to avoid the timeout issues during update package installation.


upgrade-log

I tried a few more times, waited a while, tried again and still no joy. A bit of Googling and I cam across a few posts related to update package install issues, this one on SSE being the best:

https://sitecore.stackexchange.com/questions/2772/problems-while-installing-an-update-package

There was lots of useful info here, some of it seemed to help, some of it didn’t.

Interestingly a number of people reported having this issue on other environments where connections might have more latency such as UAT or Production.

How I fixed it

I tried doing just a few of the things mentioned in this SSE post (and others I found) but in the end I needed to do all of the following to get the 8.2 update 7 update package to finish installing:

I thought it would be useful to share this so others can quickly move past these errors without wasting lots of time like I did.

Also I’ve not tried this in Sitecore 9 but I’d imagine most of these steps will still help (some updates will likely be needed to the config patch file for role based config).

Steps to resolve the issue

    1. executionTimeout – Edit the web.config and change the following setting for executionTimeout to set it to 18000:

      <httpRuntime targetFramework=”4.6.1″ maxRequestLength=”512000″ executionTimeout=”18000″ enableKernelOutputCache=”false” relaxedUrlToFileSystemMapping=”false” requestValidationMode=”4.0″ enableVersionHeader=”false” />

    2. Ping Maximum Response Time – In IIS, go to the app pool used by Sitecore and either change the ‘Ping Maximum Response Time (seconds)’ to 600 seconds or other larger value or set ‘Ping Enabled’ to false.
    3. Clear Down Previous Upgrade Files & Logs – Remove/Archive any folders here: \temp\__Upgrade. It’s also worth clearing down your Sitecore logs to make it easier to debug.
    4. Config Patch – Apply the config patch file below (add any additional indexes to disable)
    5. Try Again – Re-start the installation of the Update and package. Hopefully it succeeds this time!
    6. Undo Config Updates – Roll back the updates made in steps 1,2 and 4.

Config Patch

The following config patch should be copied into your /App_Config/Include folder. Please add any other custom indexes that you need to disable or make changes if you have renamed any.

Also Please ensure you delete this patch file after you have completed the update.

Some useful links:

https://sitecore.stackexchange.com/questions/2772/problems-while-installing-an-update-package

https://sitecorebasics.wordpress.com/2014/06/21/sitecore-version-upgrade-troubleshooting-basics

https://sitecorebasics.wordpress.com/2012/02/26/browser-timeout-error-while-doing-sitecore-version-upgrade

https://kiranpatils.wordpress.com/2012/02/26/long-running-processes-and-browser-timeout-issue-mainly-internet-explorer

Anyways I hope this is helpful for others who have this issue.

Published by

Adam Seabridge

I am a Freelance Sitecore Developer and 7x Sitecore Technology MVP (2024 - 2018). I have been working with Sitecore since 2013. You can reach me on twitter @billyjava or comment below if you have any questions or feedback.

Leave a Reply

Your email address will not be published. Required fields are marked *