There was a problem and we can't open this document
Published Jan 22 2019 02:44 AM 5,505 Views
Microsoft

First published on TECHNET on Oct 17, 2016

I've been running into following scenario for the second time now, that's why I decided to share my experience with you.

 

A customer just set up an Office Web Apps Server 2013 farm. After finishing the Office Web Apps installation/configuration, SharePoint WOPI bindings have been set up properly. As the customer wanted to check Office Web Apps funtionality, he had to deal with a strange misbehaviour.

 

Summary of what the customer did so far:




    • Installing Office Web Apps 2013 binaries

 

    • Installing a valid SSL certificate for the Office Web Apps URL

 

    • Creating a DNS record for the Office Web Apps Server URL

 

    • Configuring Office Web Apps Server 2013

 

 

    • Succesfully creating SharePoint Wopi binding to the Office Web Apps Server



Testing the Office Web Apps Server functionality in the context of a regular SharePoint user account (do not test using the System/farm account - this would result in an error) leads to no success: After clicking on a Word document, the browser is obviously communicating with Office Web Apps webservices. You could tell by the appearing logos and toolbars within the browser. We are hitting the Office Web Apps:







Anyway, the request leads to following website error in the browser after some seconds:








Sorry, there was a problem and we can't open this document. If this happens again, try opening the document in Microsoft Word.




At the same time, two unexpected errors are tracked in the Trace log on the Office Web Apps Server:





Product: Office Web Apps
Category: WAC Hosting Interaction
Level: Unexpected
Message: HttpRequestAsync, (WOPICheckFile,WACSERVER) no response [WebExceptionStatus:ConnectFailure, url:https://portal.randomdomain.com/sites/randomsite/_vti_bin/wopi.ashx/files/97e7e3948a784b8fae43932af0..., exception:System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.50.50:443
at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) -
-- End of inner exception stack trace ---
at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
at Microsoft.Office.Web.Apps.Common.HttpRequestAsync.GetResponseCallback(IAsyncResult asyncResult)]


Product: Office Web Apps
Category: WAC Hosting Interaction
Level: Unexpected
Message: WOPI CheckFile: Catch-All Failure [exception:Microsoft.Office.Web.Common.EnvironmentAdapters.UnexpectedErrorException: HttpRequest failed ---> Microsoft.Office.Web.Apps.Common.HttpRequestAsyncException: No Response in WebException ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.50.50:443
at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) -
-- End of inner exception stack trace ---
at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
at Microsoft.Office.Web.Apps.Common.HttpRequestAsync.GetResponseCallback(IAsyncResult asyncResult) -
-- End of inner exception stack trace --- -
-- End of inner exception stack trace ---
at Microsoft.Office.Web.Apps.Common.WopiDocument.LogAndThrowWireException(HttpRequestAsyncResult result, HttpRequestAsyncException delayedException)
at Microsoft.Office.Web.Apps.Common.HttpRequestAsync.End()
at Microsoft.Office.Web.Apps.Common.WopiDocument.GetWopiRequestResultWithRetry(Int32 maxSize, MemoryStream ms, WopiRequest wopiRequest)
at Microsoft.Office.Web.Apps.Common.WopiDocument.CheckWopiFile()].




Solution:

 

So what was the issue here? SharePoint successfully initiated communication to the Office Web Apps Server, by generating a proper WopiFrame link. This indicates things seems to be okay on the SharePoint side. By looking closer to the Office Web Apps machine, I noticed DNS name resolution was not properly working . I checked whether the Office Web Apps Server could resolve the SharePoint Web Application URL, in order to find the way back to the SharePoint URL, the request was initiated from. That was not the case.

 

The customer was currently in preparation for a SharePoint migration (SP2010 >> SP2013). SharePoint URLs would stay the same on the target farm. For that reason, SharePoint URLs have been specified in the hosts file of all relevant test clients and on the SharePoint 2013 servers itself. On the Office Web Apps servers, nobody thought about that issue, therefor the Office Web Apps webservices pulled the IP from the DNS that was linked to the SharePoint 2010 system.




Conclusion:

 

Make sure that the correct IP adress gets resolved for the SharePoint Web Application Office documents are stored in and requests are initiated from. Name resolution is not just important for the clients, it has to work properly on the Office Web Apps Server also, in order to find the way back to SharePoint.




This scenario is also valid for Offce Online Server 2016 and SharePoint 2016.

1 Comment
Version history
Last update:
‎Mar 01 2020 04:30 PM
Updated by: