Get Exchange to use single host Certificate

While moving to office 365 some peoples exchange 2007 do not have correct certificates for the move.

Once a correct certificate is installed say “”

you can use the following script;


Get-ClientAccessServer $CName | Set-ClientAccessServer -AutodiscoverServiceInternalUri https://$URL/autodiscover/autodiscover.xml
Get-WebServicesVirtualDirectory -Server $CName | Set-WebServicesVirtualDirectory -InternalUrl https://$URL/ews/exchange.asmx
Set-OWAVirtualDirectory -identity “$cname\owa (Default Web Site)” -InternalURL https://$URL/owa -ExternalURL https://$URL/owa
Get-OABVirtualDirectory -Server $CName | Set-OABVirtualDirectory -InternalURL https://$URL/OAB -ExternalURL https://$URL/OAB
Get-ActiveSyncVirtualDirectory -Server $CName | Set-ActiveSyncVirtualDirectory -InternalURL https://$URL/Microsoft-Server-ActiveSync -ExternalURL https://$URL/Microsoft-Server-ActiveSync
Set-OutlookAnywhere -identity “$cname\RPC (Default Web Site)” -ExternalHostname $URL

Boom this into powershell happy days

Leave a Reply

Your email address will not be published. Required fields are marked *

Blue Captcha Image