Friday, June 6, 2008

SPS2003 to MOSS In Place Upgrade fails due to System.OutOfMemoryException error

My colleagues and I have seen a few instances where a SPS2003 to MOSS in place upgrade has failed after an excessive amount of time. When investigating the upgrade.log file it reports that a "System.OutOfMemoryException " error has occured right around the 2/3 to 3/4 mark of the upgrade and the upgrade process stops. Doing a little digging around the Interweb there were a couple of helpful postings and KB articles that describe the situation and the potential fixes.

The likely culprit to this issue is IIS. During the upgrade process the sites you are migrating are utilizing an IIS Worker process called W3wp.exe, and this process is the most likely cause of the errors. It is not necessarily the size of the sites you are migrating, but the number of sites.

Microsoft recommends utilizing Web Gardening within IIS to assign multiple W3wp.exe processes to the MSSharePointPortalAppPool so that there are more processes available to carry the load of the upgrade. This should allow the upgrade to run faster as well as complete without the memory errors. Within the KB Article they recommend 4 W3wp.exe processes for a 120 sites as an example, and in your case it may vary as to what your server can handle based on memory and processor.

In order to do this in IIS 6.0, within the Computer Management/Services and Applications/Internet Information Service right click on the MSSharePointPortalAppPool and select properties. When that box appears select the Performance tab, and at the bottom there is an entry for Web Garden/ Maximum number of worker processes. The default value is 1 Out of the Box, increase this to whatever value you desire (it can go into the hundreds), in our cases we have recommended 5-10 depending on the amount of sites and memory processor speed, there really is no set formula we could find, just trial and error.

This posting is mostly for my own recollection, but I hope this can help people who may have seen this issue in the past.

Happy SharePointing!
Cheers.
Bryan

No comments: