Check out the whole SharePoint 2013 Solution Series
New Titles Added Weekly!
I wanted to evaluate Office Web Apps Server in SharePoint 2013 so I could see what the document previews would look like and understand the overall editing functionality. Therefore, I hijacked one of my staging servers and decided to install Office Web Apps Server. The server you choose can't have SharePoint running on it or any web application running on port 80. Also, Microsoft Office (or any Office component) cannot be installed.
The OS on my server was Windows Server 2008 R2 so I had to follow those directions. For Windows Server 2008 R2 you need to have the following:
Apparently this server did not have PowerShell 3.0 or the KB2592525 patch. So I needed to download and install those items first.
Then I needed to run add the proper roles using the following in PowerShell:
Import-Module ServerManager
Add-WindowsFeature Web-Server,Web-WebServer,Web-Common-Http,Web-Static-Content,Web-App-Dev,Web-Asp-Net,Web-Net-Ext,Web-ISAPI-Ext,Web-ISAPI-Filter,Web-Includes,Web-Security,Web-Windows-Auth,Web-Filtering,Web-Stat-Compression,Web-Dyn-Compression,Web-Mgmt-Console,Ink-Handwriting,IH-Ink-Support
I noticed in the output as shown in the image, that a restart was needed. So I did not even take a chance and rebooted the server.
Next it was time to install the Office Web Apps Server. I just searched for the product and found the download:
I downloaded the package and ran the installation - pretty straightforward.
Next it was time to create the new Office Web Apps Farm on the server via PowerShell. Since this was for evaluation purposes, I used the test environment configuration:
Import-Module OfficeWebAppsNew-OfficeWebAppsFarm –InternalURL http://servername –AllowHttp -EditingEnabled
Since I enabled editing, I needed to confirm the operation:
The operation resulting with all of the properties being displayed:
The next step was to test the Office Web Apps server using a browser to confirm that http://servername/hosting/discovery produced a wopi-discovery response. It did:
So that was it on the Office Web Apps server side. Now I needed to switch the the SharePoint 2013 server and do some magic there.
Create the new binding:
New-SPWOPIBinding -ServerName <WacServerName> -AllowHTTP
Set the zone:
Set-SPWopiZone –zone “internal-http”
If you are using HTTP, you need to allow OAuth over HTTP by using the following commands:
$config = (Get-SPSecurityTokenServiceConfig)
$config.AllowOAuthOverHttp = $true
$config.Update()
I didn't need to do this previously but while I was setting up my production server, I ran into an OWA issue. The answer was to run the above commands which I found in a forum who received the information from here.
That's it! Bring up a document library with Office documents:
Search for Office documents: (may need to perform a full crawl before the preview kicks in)
This was very easy to install and implement! I was very suprised it worked the first time. It took a bit for everything to warm up and work but I really did not have to do much fiddling!
Hi Steven,
ReplyDeleteThanks for this great article. I'm having troubles while binding the office web app server with SharePoint server. Whenever I run New-SPWOPIBinding command, it comes up with an error..the server did not respond. I've tried it with -allowhttp parameter as well and still getting the same error. Any suggestions would be great help. Thanks
Can you ping your Office Web Apps server from one of the SharePoint boxes? Just to confirm, you installed Office Web Apps on a different server that doesn't have SharePoint, correct?
DeleteThanks for the reply Steven.
ReplyDeleteI'm now one step ahead, I managed to bind the two servers by restarting my office web app server. Now I can preview documents from the office web app server but still no luck with SharePoint Server. I still can't ping office web app server from the SharePoint Server. I don't know what the problem is now.
Thanks
Thanks for the quick reply.
ReplyDeleteI've installed office web apps server on a different server. I've managed to bind the two servers by restarting the office web app server. The problem now is I can preview documents in the office web app server but not in the SharePoint server. I still can't ping office web app server from the SharePoint server and I don't understand why.
Windows firewall was turned on so it is pinging now after turning it off.
ReplyDeleteWindows firewall was turned on but it is pinging now after turning it off
ReplyDeleteThanx a lot Steve...
ReplyDeleteIt worked for me too. Its very nice and helpful article.
I have one question - When I search word document and open it on search page, it opens the document in word client app. But when I open the same document from library, it opens it in Web App. While Excel files are always opened in Web App.
Why so in case of word documents ?
Check your WOPI Bindings and make sure the Open is enabled for Word. Get-SPWOPIBinding from the SharePoint 2013 Management Console.
DeleteHi Steve,
ReplyDeleteNice article.
Do we definitely need seperate Office web app server for document preview in Sharepoint 2013 ?
Regards
Mani
Yes. It can't run on a server that is running SharePoint.
DeleteThanks Steve,
ReplyDeleteHow do you configure this if you want to edit files in the same farm from both internal networked machines and an external secure portal? Say, office..net
and office.externalnetwork>.com
I also assume you would have to expose a SSL interface on the Office Web App server on the external firewall.
Regards,
Paul.
You need to set the zone to "external". When you setup the OWA farm you provide both the internal and external URL. I am not sure about the SSL and firewall. You would think you would need to expose it but it may just work through the external SharePoint bindings. I don't have an external environment to test.
Deletehttp://technet.microsoft.com/en-us/library/jj219455.aspx#singleHTTPS
DeleteHi Steve,
ReplyDeletere. above - I finally got this to work - but there are a lot of "gochas". You do need to provide both urls. If your internal SharePoint url is http then you will need to allow oauth as above, and use the -allowhttp switch.
Also you will need a certificate with a SAN (Subject Alternative Name) - basically an alternative host name for internal use. This means you can use the cert on both internal and external interfaces. This is probably necessary because if you supply both external and internal urls for the office web farm the wopi binding (get-spwopibinding on the sharepoint server) will be automatically set to external-https. As you said, you need to set the matching zone (set-spwopizone) to https-external.
It is also possible to get this working without similar internal and external domain names. The Microsoft documentation tends to use contoso.com for both domains - but you can use yourdomain.com and somethingelse.internal equally well.
In addition you need to add trusted host domains to the owa farm using new-officewebappshost-domain . In our environment I had to use the EXACT host header of the Web Application or I got errors from the owa document display page.
Hope this helps any further enquiries,
Thanks
Paul.
Awesome! Thanks for the update! I appreciate it.
Deletegetting server not responding warning when trying to create a new spwopibinding with htttp. It used to work earlier but when we tried to remove the binding and add it again, for some reason it doesnt work.We tried pinging the server from application server and everything is fine. Not sure why it is unable to bind.
ReplyDeleteAny ideas are highly appreciated.
Thanks
Did you try restarting the Office Web Apps server?
DeleteThanks for the reply. Yes, we restarted both the web apps server in the farm.
ReplyDeleteFor the Apps Server:
DeleteMake sure that http://servername/hosting/discovery still produces output.
Insure that the World Wide Web Publishing service is started.
IIS - Make sure the sites are started and running
On the SharePoint server, re-issue the OAuth:
Delete$config = (Get-SPSecurityTokenServiceConfig)
$config.AllowOAuthOverHttp = $true
$config.Update()
Thanks Steve,
Deletediscovery still produces output.
Will try the rest and let you know.
Hi, we follow these steps but we are having an issue. It says Sorry Something went wrong, we are not using the System Account to login. What can be the problem? Did you guys know?
ReplyDeleteAre you using http or https? If http, did you run the PowerShell commands to allow oAuth?
DeleteI am having the same problem, the preview comes up, but in the preview window it says something went wrong. Was there an answer to this?
DeleteSame questions - Are you using http or https? If http, did you run the PowerShell commands to allow oAuth?
DeleteHTTP and Yes I did
DeleteThank You, Great!
ReplyDeleteRockie
Hi, I get this error in this step New-SPWOPIBinding -ServerName “Your Web Apps ServerName” -AllowHTTP
ReplyDeletePS C:\Users\administrator.SEWSMX> New-SPWOPIBinding -ServerName OfficeWebApps.se
wsus.com.mx -AllowHTTP
New-SPWOPIBinding : Sorry, we have encountered an error and New-SPWOPIBinding
has failed.
At line:1 char:1
+ New-SPWOPIBinding -ServerName OfficeWebApps.sewsus.com.mx -AllowHTTP
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Microsoft.Share…tNewWOPIBinding
:SPCmdletNewWOPIBinding) [New-SPWOPIBinding], SPCmdletException
+ FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletNewWOPIB
inding
Make sure you can ping OfficeWebApps.sewsus.com.mx. Were you able to get to the wopi discovery?
ReplyDeleteyes i can, the firewall is off in the two servers, in the server of OWA i test with the discovery and show the XML perfect, in my server of Sharepoint i have a project server too, do you know what is the problem?
DeleteCan you hit the discovery from the SharePoint server as well as a local browser?
DeleteTry the binding with the actual server name not the dns name
Deleteyes I can hit the discovery from my SharePoint server and is successful, now i try with only the name of server but nothing :(
DeleteWhen you performed the New-OfficeWebAppsFarm did you use the servername or dns name? If you used the dns, try using the servername.
DeleteDid you get it working Ivan?
Deletehi, i found the error, in my configuration of internet explorer have the proxy active, the solution is easy, dont have a proxy or configure the proxy server to permission acces, thank you for you help steve.
DeleteHi, i have a same issue , my internet explorer dont have proxy. Please help!
Deletewhen i come to this step to test the Office Web Apps server using a browser to confirm that http://sp2013/hosting/discover to produced a wopi-discovery response. ..... Page not found come .. please help.
ReplyDeleteIs sp2013 your Office Web Apps server? Looks like the SharePoint server to me.
DeleteI had to add
ReplyDelete$config.AllowMetadataOverHttp = $true
in addition to
$config.AllowOAuthOverHttp = $true
for mine to work properly, so just wanted to share that.
Thanks! I may do that just in case.
DeleteCan you install Workflow Manager 1.0 on a Office Web app server instance?
ReplyDeleteThe OWS server uses IIS heavily. OWS needs a dedicated server without anything else running on it. I would think there would be conflicts if you attempted to run WF Manager on the same server.
DeleteHi Steve,
ReplyDeleteGood article! Just want to confirm that you only need to do the binding on the Application server that hosts Central Administration and not the other application servers in the Sharepoint 2013 farm. Is this correct.
Thanks
Shana
Yes you only need to run it once on the farm. Doesn't matter which server.
Delete