Applies to: Exchange Server 2013

Topic Last Modified: 2012-10-03

By default Microsoft Exchange Server 2013 references the IP site link objects in Active Directory to help determine the least-cost routing path. However, if you determine the Active Directory IP site link costs and traffic flow patterns aren't optimal for mail routing in Exchange, you can configure settings in Active Directory that are only used by Exchange to help optimize mail flow.

What do you need to know before you begin?

  • Estimated time to complete each procedure: 15 minutes

  • You need to be assigned permissions before you can perform this procedure or procedures. To see what permissions you need, see the "Active Directory site and site link management" entry in the Mail Flow Permissions topic.

  • You can't use the Exchange admin center (EAC) to perform this procedure. You can only use the Shell.

  • For information about keyboard shortcuts that may apply to the procedures in this topic, see Keyboard Shortcuts in the Exchange Admin Center.

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

What do you want to do?

Use the Shell to configure an Exchange-specific cost on an Active Directory IP site link

Determine the name of the Active Directory IP site link for which you want to set an Exchange cost. A lower cost value indicates a more preferred route. You can examine the contents of the routing table logs and view the data in the ADTopologyPath ID section to view details about the calculated least cost routing path between two Active Directory sites.

To set an Exchange-specific cost on an Active Directory site link, run the following command:

Copy Code
 Set-AdSiteLink <ADSiteLinkIdentity> -ExchangeCost <Integer | $null>

This example sets an Exchange-specific cost of 10 on the IP site link named IPSiteLinkAB.

Copy Code
Set-AdSiteLink IPSiteLinkAB -ExchangeCost 10

This example clears the Exchange cost from the IP site link named IPSiteLinkAB.

Copy Code
Set-AdSiteLink IPSiteLinkAB -ExchangeCost $null

How do you know this worked?

To verify that you have successfully set an Exchange cost on an Active Directory site link, do the following:

  1. Run the following command:

    Copy Code
    Get-AdSiteLink | Format-List Name,ExchangeCost
    
  2. Verify the Exchange cost is configured on the Active Directory site link.

Use the Shell to configure an Active Directory site as a hub site

When a hub site exists along the least cost routing path for a message, the message must be routed through the hub site. Examine the contents of the routing table logs and view the data in the ADTopologyPath ID section to verify that the selected site exists along the least cost routing path between two Active Directory sites. If this isn't the case, you need to assign Exchange-specific costs to the IP site links to make the least cost routing path go through the selected sites.

To configure an Active Directory site as a hub site, run the following command:

Copy Code
Set-AdSite <ADSiteIdentity> -HubSiteEnabled $true

This example configures the Active Directory site named Site A as a hub site.

Copy Code
Set-AdSite "Site A" -HubSiteEnabled $true

This example removes the hub site attribute from the Active Directory site named Site B.

Copy Code
Set-AdSite "Site B" -HubSiteEnabled $false

How do you know this worked?

To verify that you have successfully configured an Active Directory site as a hub site, do the following:

  1. Run the following command:

    Copy Code
    Get-AdSite | Format-List Name,HubSiteEnabled
    
  2. Verify the HubSiteEnabled value is True for the Active Directory site.