Configure Exchange 2016 internal URLs

 

Estimated time to complete: 10 to 15 minutes

Before clients can connect to your new Exchange 2016 server from your intranet, you need to configure the internal domains, or URLs, on the Internet-facing Exchange 2016 Mailbox server’s virtual directories.

You choose whether you want users to use the same URL on your intranet and on the Internet to access your Exchange servers or whether they should use a different URL. What you choose depends on the addressing scheme you already have in place or that you want to implement. If you’re implementing a new addressing scheme, we recommend that you use the same URL for both internal and external URLs. Using the same URL makes it easier for users to access your Exchange servers because they only have to remember one address. Regardless of the choice you make, you need to make sure you configure a private DNS zone for the address space you configure. For more information about administering DNS zones, see Administering DNS Server.

For more information about internal and external URLs on virtual directories, see Virtual directory management.

  1. Open the Exchange Management Shell on your Exchange 2016 Mailbox server.

  2. Store the host name of your Exchange 2016 Mailbox server in a variable that will be used in the next step. For example, Ex2016.

    $HostName = "Ex2016"
    
  3. Run each of the following commands in the Shell to configure each internal URL to match the virtual directory’s external URL.

    
    Set-EcpVirtualDirectory "$HostName\ECP (Default Web Site)" -InternalUrl ((Get-EcpVirtualDirectory "$HostName\ECP (Default Web Site)").ExternalUrl)
    
    Set-WebServicesVirtualDirectory "$HostName\EWS (Default Web Site)" -InternalUrl ((Get-WebServicesVirtualDirectory "$HostName\EWS (Default Web Site)").ExternalUrl)
    
    Set-MapiVirtualDirectory "$HostName\mapi (Default Web Site)" -InternalUrl ((Get-MapiVirtualDirectory "$HostName\mapi (Default Web Site)").ExternalUrl)
    
    Set-ActiveSyncVirtualDirectory "$HostName\Microsoft-Server-ActiveSync (Default Web Site)" -InternalUrl ((Get-ActiveSyncVirtualDirectory "$HostName\Microsoft-Server-ActiveSync (Default Web Site)").ExternalUrl)
    
    Set-OabVirtualDirectory "$HostName\OAB (Default Web Site)" -InternalUrl ((Get-OabVirtualDirectory "$HostName\OAB (Default Web Site)").ExternalUrl)
    
    Set-OwaVirtualDirectory "$HostName\OWA (Default Web Site)" -InternalUrl ((Get-OwaVirtualDirectory "$HostName\OWA (Default Web Site)").ExternalUrl)
    
    Set-PowerShellVirtualDirectory "$HostName\PowerShell (Default Web Site)" -InternalUrl ((Get-PowerShellVirtualDirectory "$HostName\PowerShell (Default Web Site)").ExternalUrl)
    
  4. While we're in the Shell, let's also configure the Offline Address Book (OAB) to allow Autodiscover to select the right virtual directory for distributing the OAB. Run the following command to do this.

    Get-OfflineAddressBook | Where {$_.ExchangeVersion.ExchangeBuild.Major -Eq 15} | Set-OfflineAddressBook -GlobalWebDistributionEnabled $True -VirtualDirectories $Null
    

To verify that you successfully configured the internal URL on the Exchange 2016 Mailbox server virtual directories, do the following:

  1. In the EAC, go to Servers > Virtual directories.

  2. In the Select server field, select the Internet-facing Exchange 2016 Mailbox server.

  3. Select a virtual directory, and then click Edit Edit icon.

  4. Verify that the Internal URL field is populated with the correct FQDN and service as shown below:

     

    Virtual directory Internal URL value

    Autodiscover

    No internal URL displayed

    ECP

    https://owa.contoso.com/ecp

    EWS

    https://mail.contoso.com/EWS/Exchange.asmx

    Mapi

    https://mail.contoso.com/mapi

    Microsoft-Server-ActiveSync

    https://mail.contoso.com/Microsoft-Server-ActiveSync

    OAB

    https://mail.contoso.com/OAB

    OWA

    https://owa.contoso.com/owa

    PowerShell

    http://mail.contoso.com/PowerShell

Having problems? Ask for help in the Exchange forums. Visit the forums at Exchange Server, Exchange Online, or Exchange Online Protection.

  1. Open the EAC by browsing to the URL of your Exchange 2016 Mailbox server. For example, https://Ex2016/ECP.

  2. Go to Servers > Virtual directories.

  3. In the Select server field, select the Internet-facing Exchange 2016 Mailbox server.

  4. Select the virtual directory you want to change, and then click Edit Edit icon.

  5. In Internal URL, replace the host name between https:// and the first forward slash (/ ) with the new FQDN you want to use. For example, if you want to change the EWS virtual directory FQDN from Ex2016.corp.contoso.com to internal.contoso.com, change the internal URL from https://Ex2016.corp.contoso.com/ews/exchange.asmx to https://internal.contoso.com/ews/exchange.asmx.

  6. Click Save.

  7. Repeat steps 5 and 6 for each virtual directory you want to change.

    NoteNote:
    The ECP and OWA virtual directory internal URLs must be the same.
    You can’t set an internal URL on the Autodiscover virtual directory.

To verify that you successfully configured the internal URL on the Exchange 2016 Mailbox server virtual directories, do the following:

  1. In the EAC, go to Servers > Virtual directories.

  2. In the Select server field, select the Internet-facing Exchange 2016 Mailbox server.

  3. Select a virtual directory, and then click Edit Edit icon.

  4. Verify that the Internal URL field is populated with the correct FQDN. For example, you may have set the internal URLs to use internal.contoso.com.

     

    Virtual directory Internal URL value

    Autodiscover

    No internal URL displayed

    ECP

    https://internal.contoso.com/ecp

    EWS

    https://internal.contoso.com/EWS/Exchange.asmx

    Mapi

    https://mail.contoso.com/mapi

    Microsoft-Server-ActiveSync

    https://internal.contoso.com/Microsoft-Server-ActiveSync

    OAB

    https://internal.contoso.com/OAB

    OWA

    https://internal.contoso.com/owa

    PowerShell

    http://internal.contoso.com/PowerShell

Having problems? Ask for help in the Exchange forums. Visit the forums at Exchange Server, Exchange Online, or Exchange Online Protection.

 
Show: