This will get your autodiscover service in Exchange 2007/2010 up and running.
Configure the EWS directory:
# Set-WebServicesVirtualDirectory -Identity “CAS01\EWS (Default Web Site)” -InternalUrl https://CAS01.contoso.local/EWS/Exchange.asmx -ExternalUrl https://mail.contoso.com/EWS/Exchange.asmx
# Set-WebServicesVirtualDirectory -Identity “CAS02\EWS (Default Web Site)” -InternalUrl https://CAS02.contoso.local/EWS/Exchange.asmx -ExternalUrl https://mail.contoso.com/EWS/Exchange.asmx
Configure the OWA directory:
# Set-OwaVirtualDirectory -Identity “CAS01\Owa (Default Web Site)” -InternalUrl https://CAS01.contoso.local/owa -ExternalUrl https://mail.contoso.com/oab
# Set-OwaVirtualDirectory -Identity “CAS02\Owa (Default Web Site)” -InternalUrl https://CAS02.contoso.local/owa -ExternalUrl https://mail.contoso.com/oab
Configure the OAB directory:
# Set-OABVirtualDirectory -Identity “CAS01\OAB (Default Web Site)” -InternalUrl https://CAS01.contoso.local/oab -ExternalUrl https://mail.contoso.com/oab
# Set-OABVirtualDirectory -Identity “CAS02\OAB (Default Web Site)” -InternalUrl https://CAS02.contoso.local/oab -ExternalUrl https://mail.contoso.com/oab
Configure AutodiscoverUri:
# Set-ClientAccessServer -Identity CAS01 -AutoDiscoverServiceInternalUri https://CAS01.contoso.local/autodiscover/autodiscover.xml
# Set-ClientAccessServer -Identity CAS02 -AutoDiscoverServiceInternalUri https://CAS02.contoso.local/autodiscover/autodiscover.xml
Test Outlook autodiscover:
# Test-OutlookWebServices -ClientAccessServer CAS01
My Test lab setting under below
EWS settings checking by using this command
[PS] C:\Windows\system32>Get-WebServicesVirtualDirectory |fl identity,internalurl,externalurl
Identity : CAS01\EWS (Default Web Site)
InternalUrl : https://mail.cas01.com/EWS/Exchange.asmx
ExternalUrl : https://mail.cas01.com/ews/exchange.asmx
Identity : CAS02\EWS (Default Web Site)
InternalUrl : https://mail.cas02.com/EWS/Exchange.asmx
ExternalUrl : https://mail.cas02.com/ews/exchange.asmx
Configuring EWS by using the command
Set-WebServicesVirtualDirectory -Identity “CAS01\EWS (Default Web Site)” -InternalUrl https://mail.testdomain.com/EWS/Exchange.asmx -BasicAuthentication:$true
If you are having two CAS server you have to run this command on both servers
[PS] C:\Windows\system32>Set-WebServicesVirtualDirectory -Identity “CAS02\EWS (Default Web Site)” -InternalUrl https://mail.testdomain.com/EWS/Exchange.asmx -BasicAuthentication:$true
For Autodiscover nad Out Of Office configuration
[PS] C:\Windows\system32>Get-ClientAccessServer |fl -Identity,autodiscoverserviceinternaluri
AutoDiscoverServiceInternalUri : https://mail.testdomain.com/Autodiscover/Autodiscover.xml
AutoDiscoverServiceInternalUri : https://mail.testdomain.com/Autodiscover/Autodiscover.xml
For Setting autodiscover by using shell
[PS] C:\Windows\system32>Set-ClientAccessServer -Identity CAS01 -AutoDiscoverServiceInternalUri https://mail.testdomain.com/Autodiscover/Autodiscover.xml
[PS] C:\Windows\system32>Set-ClientAccessServer -Identity CAS02 -AutoDiscoverServiceInternalUri https://mail.testdomain.com/Autodiscover/Autodiscover.xml
E-Mack said:
This works – thank you. It is amazing that I read 100 pages of information to finally land here to get it resolved.
Single SBS server – internal url and external need to be the same (create a .com for local resolution in DNS) OR get another certificate for the internal urls.
mshiyas said:
If the internal and external URL is same you can use same certificate in internal and external URL
Static said:
I almost never leave comments but just had to say thanks. I was fighting with this problem for most of the day. Now on the the next fire!!
Paul said:
This was very helpful, thank you for putting all this information down in one place!
Mark Jane said:
<<<
Configure the OWA directory:
# Set-OwaVirtualDirectory -Identity “CAS01\Owa (Default Web Site)” -InternalUrl https://CAS01.contoso.local/owa -ExternalUrl https://mail.contoso.com/oab
<<
I think you need to update ExternalUrl to /owa, not /oab