Friday, January 10, 2014

Simplify the OWA URL

Below is a quick powershell one-liner to setup your OWA URL to redirect nicely from mail.contoso.com to mail.contoso.com\owa as documented in http://technet.microsoft.com/en-us/library/aa998359(v=exchg.150).aspx


  1. Import-Module WebAdministration  
  2. Set-WebConfiguration system.webServer/httpRedirect "IIS:\sites\Default Web Site" -Value @{enabled="true";destination="https://mail.contoso.com/owa";exactDestination="false";httpResponseStatus="Found";childOnly="true"}   

or you can do it via the ol' Error Pages with this command


  1. .\appcmd.exe set config -section:system.webServer/httpErrors /+"[statusCode='403',responseMode='Redirect' ,path='https://mail.contoso.com/owa']" /commit:apphost