Applies to: Exchange Server 2010 SP3, Exchange Server 2010 SP2

Topic Last Modified: 2009-12-07

Internal message delivery involves a routing process that relays e-mail in the following ways:

For more information about how Exchange makes routing decisions, see Understanding Message Routing.

Looking for management tasks related to message routing? See Managing Message Routing.

Contents

Routing Messages for Delivery to Exchange 2010 Servers

Routing Messages for Delivery to Exchange 2007 Servers

Routing Messages for Delivery to Exchange 2003 Servers

Routing to Public Folders

Routing Messages for Delivery to Exchange 2010 Servers

 

In Exchange 2010, after a message is received by the Hub Transport server, the message is added to the Submission queue. Messages move from the Submission queue through the categorizer. When the message is categorized, a recipient's e-mail address is resolved to an object in Active Directory. This query determines the mailbox associated with that e-mail address and which Mailbox server is hosting that mailbox.

After information about the recipient is resolved, the next step is resolving the Mailbox server to an Active Directory site. This Active Directory site information is stamped on the message as the NextHopSolutionKey attribute. The enhanced DNS component of the Microsoft Exchange Transport service accesses the topology information to determine which Hub Transport servers are located in the same site as the destination Mailbox server. A list of Hub Transport servers in the Active Directory site is then referenced to determine where to route the message. If the destination Mailbox server is located in the same site as the querying Hub Transport server, that Hub Transport server queues the message for local delivery. If the destination Mailbox server is located in a different site, the local Hub Transport server queues the message for remote delivery to that Active Directory site.

A message queued for local delivery is submitted to the destination mailbox store by the store driver. The message is transferred from the Hub Transport server to the Mailbox server by using an Exchange remote procedure call (RPC).

A message queued for delivery to a remote Active Directory site is transferred by using SMTP. Before the message is relayed, the routing component of the categorizer selects the least cost routing path. The method for determining the least-cost routing path is explained in detail in "Determining the Least-Cost Routing Path" in Understanding Message Routing.

Return to top

Routing Messages for Delivery to Exchange 2007 Servers

Due to the changes made to the Exchange Server Object (XSO) model in Exchange 2010, Exchange 2010 Hub Transport servers can't pick up messages from and deliver messages to Exchange 2007 Mailbox servers. Similarly, Exchange 2007 Hub Transport servers can't communicate with Exchange 2010 Mailbox servers. As a result, to have both Exchange 2010 and Exchange 2007 in the same Active Directory site, you must maintain both versions of Hub Transport servers in that site.

When a Hub Transport server queries Active Directory to determine the Mailbox server hosting the destination mailbox, it also retrieves the version of the Mailbox server. If the Mailbox server is an Exchange 2007 server that's in the same site as the Hub Transport server, the Hub Transport server will relay the message to an Exchange 2007 Hub Transport server in the same Active Directory site. The process of using the version information to make routing decisions is called versioned routing and is explained in detail in Upgrade from Exchange 2007 Transport.

If the Mailbox server is in a different Active Directory site, the message is queued for delivery to that remote site and is transferred by using SMTP.

Return to top

Routing Messages for Delivery to Exchange 2003 Servers

The routing topology and components of Exchange 2010 differ significantly from those of Exchange 2003 but generally correlate in the following ways:

  • The Active Directory site in Exchange 2010 correlates to routing groups in Exchange 2003.

  • IP site links in Exchange 2010 correlate to the concept of routing group connectors in Exchange 2003.

  • The functionality of the Hub Transport server role in Exchange 2010 correlates to the functionality of a dedicated bridgehead server in Exchange 2003.

However, each Exchange version differs in the method used to determine routing paths. For more information about the routing differences, see Upgrade from Exchange 2003 Transport.

A message relayed from a Hub Transport server to an Exchange 2003 server for delivery to a recipient mailbox located on an Exchange 2003 server must be relayed across a routing group connector. All Exchange 2010 servers are associated with a single routing group named Exchange Routing Group (DWBGZMFD01QNBJR) for the purposes of routing to earlier versions of Exchange when Exchange 2010 coexists in the same organization with Exchange 2003. Placement of Exchange 2010 and earlier versions of Exchange in the same routing group isn't supported. Therefore, at least one routing group connector will always separate Exchange 2010 servers from Exchange 2003 servers.

When an Exchange 2010 Hub Transport server determines the least-cost routing path to an Exchange 2003 server, the routing component of the Microsoft Exchange Transport service uses the following algorithm to select the least-cost routing path to a computer running Exchange 2003:

  1. Examine all possible routing paths across routing group connectors and select the routing path that has the least total cost.

  2. If more than one routing path has the same cost, examine all possible routing paths across IP site links to reach the first routing group connector and select the routing path that has the lowest total IP site link cost.

  3. If more than one routing path has the same routing group cost and has the same IP site link cost, select the routing path that includes the least number of hops.

  4. If more than one routing path has the same routing group cost, the same IP site link cost, and the same number of hops, select the routing path where the name of the last Active Directory site before the destination site has the lowest alphanumeric value.

The following figure shows an example of a routing topology where Exchange 2010 and Exchange 2003 coexist.

Route selection - Exchange 2007 to Exchange 2003

In this example, a message is being routed from a Hub Transport server in Site A to an Exchange 2003 server located in routing group 2. Two possible routing paths exist to reach routing group 2:

  • Option 1: From routing group connector A3 at a cost of 10, to routing group connector 2-3 at a cost of 20. This routing path has a total cost of 30.

  • Option 2: From routing group connector C1 at a cost of 10, to routing group connector 1-2 at a cost of 10. This routing path has a total cost of 20.

In this example, Option 2 has a lower total routing group connector cost, and the message is routed from the Hub Transport server in Site A, to a Hub Transport server in Site C where it's queued for delivery by using routing group connector C1.

The previous example shows how the routing decisions may not result in optimal routing due to the assigned costs on the routing group connectors. To maintain optimal routing, you may need to modify the routing group connector costs you have in your organization. The following figure shows the same topology, but with the cost of routing group connector 2-3 changed to 10.

Route Exchange 2007 to Exchange 2003 revised cost

Again, two possible routing paths are available to reach routing group 2:

  • Option 1: From routing group connector A3 at a cost of 10, to routing group connector 2-3 at a cost of 10. This routing path has a total cost of 20.

  • Option 2: From routing group connector C1 at a cost of 10, to routing group connector 1-2 at a cost of 10. This routing path has a total cost of 20.

In this scenario, both options have the same total routing group connector cost. Routing next evaluates the cost of the IP site links that must be crossed to reach the first routing group connector. From Site A, the IP site link cost to reach routing group connector A3 is zero, and the cost to reach routing group connector C1 is 20. Therefore, the routing path described in Option 1 is selected.

Return to top

Routing to Public Folders

Public folders can be mail-enabled in Exchange. Users can send messages to mail-enabled public folders just like any other recipient. When a Hub Transport server receives a message sent to a mail-enabled public folder, the following routing process applies:

  1. The categorizer must determine which public folder hierarchy in which the public folder resides.

  2. The categorizer looks up the homeMDB attribute for the public folder. The homeMDB attribute identifies the public folder hierarchy where the destination public folder is located.

  3. Based on the routing table calculations performed by the Microsoft Exchange Transport service, and described in "Selecting the Destination Public Folder Database" later in this topic, the preferred public folder database is used to determine which public folder hierarchy contains a replica of the destination public folder.

    If the preferred public folder database is located in the same Active Directory site as the routing Hub Transport server, message processing proceeds as described in step 4 in this section.

    If the preferred public folder database is located in a remote Active Directory site, the message is relayed to that site by using the least cost routing path. The message categorization process described in step 1 and step 2 earlier in this section are repeated by the Hub Transport server that receives the message in the remote site.

    If the preferred public folder database is located on an Exchange 2007 or Exchange 2003 server, the message is relayed to the Exchange 2007 Hub Transport server or the Exchange 2003 bridgehead server, and message delivery is determined by the earlier version of Exchange.

  4. The Hub Transport server establishes a connection to the store driver on the Mailbox server that contains the preferred public folder database. The public folder database is queried to determine whether content for the public folder is available. The identity of the destination folder is referenced by the legacyExchangeDN attribute, and content availability is determined by the value of the IsContentAvailable attribute. The store driver either accepts the message for delivery, or if the folder contents aren't available locally, the store driver responds with a list of alternative servers that contain a replica of that public folder.

    The behavior of returning an alternative list of servers is known as store override. The alternative list of servers that contain the public folder replica is listed in the same order provided in client folder referrals, and the top entry is chosen by transport. This referral is provided to routing as the destination to which the message should be routed. For more information about client folder referrals, see Configure Public Folder Referrals.

  5. If store override occurs, the Hub Transport server uses the routing table to determine the least cost routing path to the server that contains the preferred public folder replica and routes the message to that destination.

  6. The message is delivered to the public folder store.

Selecting the Destination Public Folder Database

Public folders are stored in databases created on Mailbox servers. For efficiency and fault tolerance, you can replicate the content in your public folders to multiple Mailbox servers. Public folder content exists only in Exchange databases configured to have a replica of a specific folder, whereas the hierarchy is replicated to all public folder databases. Content and hierarchy information are replicated separately.

Public folder hierarchies are retrieved when routing tables are calculated. The top-level hierarchy object has a list of all the public folder databases to which that hierarchy is replicated. This list of public folder databases is stored as the msExchOwningPFTreeBL attribute in Active Directory. The msExchOwningPFTreeBL attribute always lists the most recently added public folder databases at the top of the list.

In Exchange 2010, the preferred public folder hierarchy database is selected by using the following criteria:

  1. Ranking by the age of the public folder database   By default, public folder databases that have an age threshold of less than two days aren't considered unless the age of all public folder databases is less than the threshold or the age is unknown.

  2. Proximity   Thelocal server is preferred. If the local server doesn't contain a replica of the public folder database, a server in the same Active Directory site is preferred. If the local Active Directory site doesn't contain a replica of the public folder database, a server in a remote Active Directory site or routing group is selected as the preferred destination.

  3. Cost   If more than one remote Active Directory site or routing group contains a replica of the public folder database, the server in the Active Directory site or routing group that has the least cost routing path from the local Active Directory site is selected as the preferred destination.

If more than one server still meets the criteria, the first server in the replica list returned by Active Directory is selected.

After the hierarchy is read, Exchange then determines which public folder databases have replicas of the content. To make sure that correct message delivery can occur to the public folder replica, a preferred public folder database is selected by the routing component of the Microsoft Exchange Transport service from the msExchOwningPFTreeBL list. This selection is made by using the following evaluation process:

  1. If only a single instance of a public folder database exists, the server that hosts that database is selected.

  2. If the list contains any public folder databases located on servers running Exchange 2007 or Exchange Server 2003, these public folder databases are removed from consideration as the preferred public folder database if a replica also exists on an Exchange 2010 Mailbox server.

  3. If more than one Exchange 2010 public folder database is available, the following criteria are used to select a preferred public folder database:

    1. Ranking by the age of the public folder database   The older a public folder database is, the more likely it is to have a replica of the target public folder. Therefore, all public folder databases listed in the msExchOwningPFTreeBL list are ranked according to their date of creation by using a configurable number of days as a baseline. The age ranking for each public folder database can be one of the following, listed from best to worst:

      • More than baseline days old

      • Less than baseline days old

      • Unknown

      The public folder database that has the best age rating is selected as the preferred public folder database. By default, the baseline age for public folder replicas is two days (48 hours). You can modify this value by editing the PFReplicaAgeThreshold key in the EdgeTransport.exe.config file. This file is located in the %ProgramFiles%\Microsoft\Exchange Server\V14\Bin directory on a computer running Exchange 2010.

    2. Proximity   If more than one public folder database has the best age rating, the Mailbox server that has the best proximity rating is selected. The proximity rating for each public folder database can be one of the following, listed from best to worst:

      Local server   If the local server contains a replica of the public folder database, it's selected as the preferred destination for routing to public folders contained in that hierarchy.

      Server located in the local Active Directory site   If more than one server on the list is located in the local Active Directory site, the first server on the list is selected as the preferred destination for routing to public folders contained in that hierarchy.

      Server located in a remote Active Directory site   If the list contains servers from multiple remote Active Directory sites, the server in the Active Directory site that has the least cost routing path from the local Active Directory site is selected as the preferred destination for routing to public folders contained in that hierarchy. If there is more than one server in that site that has a replica of the public folder database, the first server on the list is selected. If more than one remote Active Directory site has the same value for the least cost routing path, the first server on the list is selected.

  4. If no public folder database replica is located on an Exchange 2010 Mailbox server, a public folder database located on an Exchange 2007 server is selected as the preferred destination. If there are no Exchange 2007 servers, a public folder database located on an Exchange 2003 computer is selected as the preferred destination for routing to public folders contained in that hierarchy. In either case, the destination public folder database is selected by the age ranking of the public folder database. The age ranking is determined by using the same method as for an Exchange 2010 server. If more than one public folder database has the same age ranking, the first server on the list is selected.

Return to top