If you would like to read the other parts in this article series please go to:
The main purpose of the Transport service (present on all Mailbox servers) is to route messages to their final destination. Routing decisions are made during message categorization, with the categorizer being the component of the Transport service that processes all incoming messages and determines what to do with them based on their destination.
Because in Exchange 2013 all Mailbox servers host the Transport service, the routing process is now fully aware of Database Availability Groups [DAGs] and uses DAG membership as a routing boundary. This way, if a Mailbox server belongs to a DAG, the primary mechanism for routing messages is closely aligned with the DAG because if the DAG spans multiple Active Directory [AD] sites, using the AD site as the primary routing boundary is inefficient.
Obviously, Exchange 2013 continues to use AD site membership as a routing boundary for Mailbox servers that do not belong to a DAG and for routing with previous versions of Exchange.
Due to the new architecture design of Exchange 2013, there are also other changes to the routing process. The diagram below helps to understand some of these changes:
Figure 2.1: Exchange 2013 Transport Pipeline
- The Transport service on a Mailbox server never communicates directly with a mailbox database. Instead, it communicates with the Mailbox Transport service which then communicates with the mailbox database on the local Mailbox server. When the Mailbox server is a member of a DAG, only the Mailbox Transport service on the Mailbox server that holds the active copy of the mailbox database accepts the message for the destination recipient;
- Remote Procedure Calls [RPCs] are only used by the Mailbox Transport service when sending messages to or receiving messages from the local mailbox database, they are never used for cross-server communication. Instead, the Mailbox Transport service and the Transport service on different Mailbox servers communicate using SMTP;
- Instead of using one queue for all destinations in a remote AD site, Exchange 2013 queues messages for specific destinations within the AD site, such as individual Send connectors;
- Linked connectors (a Receive connector linked to a Send connector) have been deprecated.
As explained previously, when an e-mail is received by the Transport service it has to be categorized. First, recipient resolution is performed after which the ultimate destination can be determined. Now comes routing, where Exchange determines how to best reach that destination. As with previous versions of Exchange, the ultimate destination for a message is called a Routing Destination (note that the following also existed before):
- Mailbox database: any recipient with a mailbox in the Exchange organization has this as the routing destination. Because public folders are now also a type of mailbox, routing messages to public folder recipients is the same as routing messages to mailbox recipients;
- Connector: this can be a Send connector for SMTP messages, a Delivery Agent connector or a Foreign connector used as a routing destination for non-SMTP messages;
- Distribution Group expansion server: when a distribution group has a designated expansion server (no longer a Transport server but a Mailbox server in Exchange 2013) that is responsible for expanding the membership list of the group, this is the routing destination.
What is different in Exchange 2013 is the notion of Delivery Groups. Each routing destination has a collection of one or more transport servers (either an Exchange 2013 Mailbox server or an Exchange 2010 Hub Transport server) that are responsible for delivering messages to that routing destination, known as a delivery group.
If the routing destination is a mailbox database, the transport servers in the delivery group are the same version of Exchange as the mailbox database. If the routing destination is a connector or a distribution group expansion server, the delivery group may contain a mixture of Exchange 2013 Mailbox servers and Exchange 2010 Hub Transport servers.
There are 5 types of delivery groups in Exchange 2013:
- Routable DAG: a collection of mailbox servers that belong to a DAG. The mailbox databases in the DAG are the routing destinations that are serviced by this delivery group. After the message arrives at the Transport service on a Mailbox server that belongs to the DAG, the Transport service routes the message to the Mailbox Transport service on the Mailbox server in the DAG that currently holds the active copy of the destination mailbox database. The Mailbox Transport service on the destination Mailbox server then delivers the message to the local mailbox database. Although a DAG may contain Mailbox servers located in different AD sites, the DAG is the delivery group boundary;
- Mailbox delivery group: a collection of Exchange servers of the same version located in one AD site. The AD site is the delivery group boundary. The mailbox databases located on Exchange 2010 Mailbox servers are serviced by the Exchange 2010 Hub Transport servers located in the AD site; the mailbox databases located on Exchange 2013 Mailbox servers in an AD site that don't belong to a DAG are serviced by the Transport service on Exchange 2013 Mailbox servers in the AD site.
How the message is delivered to the mailbox database depends on version of Exchange:
- Exchange 2013: after the message arrives at the destination Mailbox server in the destination AD site, the Transport service uses SMTP to transfer the message to the Mailbox Transport service which then delivers the message to the local mailbox database using RPC;
- Exchange 2010: after the message arrives at a random Exchange 2010 Hub Transport server in the destination AD site, the store driver on the Transport server uses RPC to write the message to the mailbox database;
- Connector source servers: a mixed collection of Exchange 2010 Hub Transport servers or Exchange 2013 Mailbox servers scoped as the source server for a Send connector, a Delivery Agent connector or a Foreign connector. The connector is the routing destination that is serviced by this routing group. When a connector is scoped to a specific server, only that server is allowed to route messages to the destination defined by the connector. This delivery group may contain Exchange 2010 Hub Transport servers or Exchange 2013 Mailbox servers located in different AD sites;
- AD site: in some circumstances, an AD site isn't the ultimate destination of a message, but the message must pass through an Exchange 2010 Hub Transport server or Exchange 2013 Mailbox server in that site before it reaches its destination;
- Server list: a collection of one or more Exchange 2010 Hub Transport servers or Exchange 2013 Mailbox servers that are configured as distribution group expansion servers. The distribution group expansion server is the routing destination serviced by this delivery group.
Delivery group membership isn't mutually exclusive. For example, an Exchange 2013 Mailbox server that is a member of a DAG can also be the source server of a scoped Send connector. This Mailbox server would belong to the routable DAG delivery group for mailbox databases in the DAG, and also a connector source server delivery group for the scoped Send connector.
When a message is to be delivered to a remote delivery group, a routing path must be determined for the message. Exchange 2013 uses the same logic as Exchange 2010 to select the routing path for a message:
- Calculate the least-cost routing path by adding the cost of the IP site links that must be traversed to reach the destination. If the destination is a connector, the cost assigned to the address space is added to the cost to reach the selected connector. If multiple routing paths are possible, the routing path with the lowest aggregate cost is used;
- If more than one routing path has the same cost, the routing path with the least number of hops is used;
- If more than one routing path is still available, the name assigned to the AD sites before the destination is considered. The routing path where the AD site nearest the destination is lowest in alphanumeric order is used. If the site nearest the destination is the same for all routing paths being evaluated, an earlier site name is considered.
This article was all about theory and more text than what I would prefer... However, it is necessary to understand how Exchange 2013 uses Routing Destination and Delivery Groups to route messages to their correct destination.
The third and final article of this series will be more interesting (I promise!) as we will be looking at how the Front End Transport and Mailbox Transport services route messages; we will trace an e-mail message through all the steps and processes discussed so far and finally we will have a look at Queues.
If you would like to read the other parts in this article series please go to: