Office WebApps Deployment Error

I was recently looking at a failed Office WebApps deployment to a SharePoint 2013 Farm. In this environment, all servers were running Windows Server 2008 R2 SP1.

  • Upon executing the New-OfficeWebAppsMachine cmdlet, the Management Shell immediately returned an error:

PF_Office WebApps Deployment Error_01

  • On initial observation, it looks like we have a serious problem but on closer insepection of the response exposes the “<h1>Server Error</h1>” message that looks like the beginings of a generic IIS 500 response. If we attempt to navigate to the WOPI discovery page, we can confirm that IIS seems to be the problematic component:

PF_Office WebApps Deployment Error_02

  • There are numerous posts on the Internet about how to expand on IIS error pages so I won’t cover that here. What I will mention though, is a quick-win that might save you some time and configuration. Log onto a Office WebApp server and navigate to http://localhost. This time, we are receiving the full ISS error information:

PF_Office WebApps Deployment Error_03

  • This error is quite common place when ASP.NET has not been correctly registered with IIS. In this scenario, .NET 4.5 was installed to the freshly built OSE as a pre-requisite for Office WebApps and all we need to do is complete the ASP.NET registration. Open PowerShell (or Command Prompt) and change the working directory to %windir%Microsoft.NETFrameworkv4.0.30319 and run aspnet_regiis.exe and ensure you pass the -ir parameter. Further reading for aspnet_regiis can be found here¬†

PF_Office WebApps Deployment Error_04

  • Now, when we try to refresh the WOPI discovery page we were hit with a blank page.

PF_Office WebApps Deployment Error_05

  • That’s my bad! I forgot to perform an IIS reset on the Office Web Apps server after registering ASP.NET

PF_Office WebApps Deployment Error_06

  • Refresh the WOPI discovery page again and we are now greeted with the XML we hoped for:

PF_Office WebApps Deployment Error_07
Transcript of errors below just for the benefit of search engines:

The content type text/html of the response message does not match the content type of the binding (application/soap+msbin1). If using a custom encoder, be sure that the IsContentTypeSupported method is implemented properly.
HTTP Error 500.21 - Internal Server Error Handler "PageHandlerFactory-Integrated" has a bad module "ManagedPipelineHandler" in its module list


About the author