Understanding the Role of Active Manager in Exchange 2010

After understanding DAG in Exchange 2010, it is also important to understand the role of Active Manager in Exchange 2010. Active Manager is a new component in in Exchange Server 2010. It replaces the failover management and resource model features in cluster service used in Exchange 2007. Windows failover cluster is still used by Exchange 2010 but there is not cluster groups or storage resources in the cluster. Cluster nodes and networks are still present but those are exclusively managed by Exchange and no cluster or cluster tools. In this article we shall look into understanding the role of Active Manager in Exchange 2010.

Understanding the Role of Active Manager in Exchange 2010

Active manager is a role that runs on a mailbox server. A single active manager role “Standalone Active Manager” which runs on a mailbox server that has no high-availability configured. Two active manager roles will be in use when the mailbox server is a member of a DAG; Primary Active Manager (PAM) and Standby Active Manager (SAM). PAM is the Active Manager in a DAG that decides which database copies will be active and passive. PAM is responsible for getting topology change notifications and reacting to server failures. SAM provides information on which server hosts the active copy of a mailbox database to other components of Exchange that are running an Active Manager client component (for example, RPC Client Access service or Hub Transport server).

The SAM detects failures of local databases and the local Information Store. It reacts to failures by asking the PAM to initiate a failover.  A SAM does not determine the target of failover, nor does it update a database’s location state in the PAM. SAM runs on all mailbox servers in a DAG except on the one where PAM is running.  To check which mailbox server currently holds the PAM role using the Get-DatabaseAvailabilityGroup command with -Status switch and selecting the parameter “PrimaryActiveManager” as shown below.

Get-DatabaseAvailabilityGroup -Status|fl Identity, PrimaryActiveManager

From the prespective of the Information Store and Extensible Storage Engine, all active managers both PAM and SAM are responsible for monitoring the health of the databases on the local server.  In the event of failure, the Active Manager notifies the PAM to initiate a fail-over. When the server with the PAM and having quorum fails, the quorum will move to another server and the server will seize the PAM role.  Because PAM stores DAG state information in the cluster database (located on the quorum), the PAM role can move without consequences.

Activation Preference:

All the monitoring of active and passive databases and coordinating the activation of database during failover or switch-over happens automatically.  However, admins can have some control over the Best Copy Selection(BCS) process. Administrator can configure a preferred activation order of database copies using the Exchange Management Console. You can edit the activation preference number to do this right click on the database copy â†’ click on. Properties  → set the Activation Preference Number and then click Apply as shown below.

Understanding the Role of Active Manager in Exchange 2010

To set the Activation Preference Number while adding a database copy, in the “Add Mailbox Database Copy” wizard change the Activation Preference Number as shown below and complete the wizard.

Understanding the Role of Active Manager in Exchange 2010

You can also change the Activation Preference number from the Exchange Management Shell(EMS) using the following command.

Set-MailboxDatabaseCopy -Identity DB01\MBG-MBX02 -ActivationPreference 2

PAM will follow the below process to bring a database copy active when it is notified by SAM or through a detection of failure.

  1. Active Manager detects a failure.
  2. PAM runs the Best Copy Selection algorithm.
  3. A process named “Attempt copy last Logs” (ACLL) will try to copy any missing log; files from the mailbox server which was hosing the active mailbox copy before the failover.
  4. PAM Issues a mount request to the Information Store through RPC. This will have two scenarios.
    • The requested database is mount successfully and made active to serve the client requests.
    • The Database failed to mount,then. PAM will perform the steps from 3 and tries to mount the next best copy if it is available.

While searching for a best copy, PAM uses certain criteria to determine the best copy to activate. Once it is located, ACLL process will run. If all missing logs have been copied successfully from the previous active database copy then the database will mount successfully without any data loss (Loss Less Fail-over). If the ACLL process fails to copy the missing logs then the AutoDatabaseMountDial is consulted.  See MailboxServer.AutoDatabaseMountDial to learn more about this property.  If the value of AutoDatabaseMountDial is more than the number of logs lost, then the database is made active. If the value configured in the AutoDatabaseMountDial is less than the number of logs lost the database will not mount. In this case either administrator must force the database to mount accepting a large data loss or until the missing logs are recovered.

Best Copy Selection Process:

The Active Manager starts the Best Copy Selection(BCS) process when a Active Database is unreachable. The BCS process will create a list of database copies which are best for the activation according to ten set of criteria. In this process any database copy which is offline or the database copy which are blocked from activation by an administrator will be ignored. In the BCS process, Active manager will create a list of database copies using the copy queue length as a Primary Key. Active Manager will use the value of ActivationPrefeence as a Seconday Key for sorting. Lowest ActivationPreference means highest priority.

When you have configured the automatic database mount dial with “Lossless” this behavior is slightly different. When an Administrator or a script performs a switch-over without specifying the target and with Lossless settings, then the. Active Manager sorts the list in ascending order just by using the value of ActivationPreference as a Primary Key.  After this the Active Manager will evaluate each database copy by using and order set of ten criteria.  Active Manager will try to find the best database which meets the set of criteria in the order shown below. Below is the table for your reference, each set of criteria.

Set of Criteria Criteria
1 It has a content index with a status of Healthy.
It has a copy queue length less than 10 log files.
It has a replay queue length of less than 50 log files.
2 It has a content index with a status of Crawling.
It has a copy queue length less than 10 log files.
It has a replay queue length of less than 50 log files.
3 It has a content index with a status of Healthy.
It has a replay queue length of less than 50 log files.
4 It has a content index with a status of Crawling.
It has a replay queue length of less than 50 log files.
5 It has a replay queue length of less than 50 log files.
6 It has a content index with a status of Healthy.
It has a copy queue length less than 10 log files.
7 It has a content index with a status of Crawling.
It has a copy queue length that is less than 10 log files.
8 It has a content index with a status of Healthy.
9 It has a content index with a status of Crawling.
10 A database with Status of Healthy, DisconnectedAndHealthy,
DisconnectedAndResynchronizing, or
SeedingSource

The Scenario

In this illustration let us visualize how does the Active Manager activates copy of a mailbox database when the Active Database is unavailable.  In this scenario I have a DAG with four members hosting one mailbox database DB01.  MBX01\DB01 is the Active Mailbox Database, all others are passive copies as shown below.

BCS Process 1

Let us assume that there is an hardware failure on MBX01, now the Active manager will create list of potential database to get it active. As per our understanding, in this scenario the Active Manager will start the BCS process using the first set of criteria. In our scenario MBX02 having zero copy queue length but the Content Index State is not healthy. MBX02 will not match with the first set of criteria in the BCS process. Now MBX04 has Content Index State as Healthy but the Copy Queue length is greater than 10 which will not satisfy the first set of criteria of the BCS process. MBX03 has potential to be an Active Mailbox database as per the first set of criteria, and hence activates the mailbox database on MBX03.

Understanding the Role of Active Manager in Exchange 2010

Once the MBX03 is active, the ACLL process will try to copy any logs that are missing from the previously active server. As soon as the ACLL process is complete, it notifies the PAM with the results of the process. If the logs are copied successfully then the database will be marked as an active copy and will be mounted with zero data loss. If the ACLL is unable to copy the logs completely, then the database is mounted as active copy with a data loss provided the AutoDatabaseMountDial value is within the configured value.  Recovers the missing data from the transport dumpster.  If the Information store do not receive a mount request from the Active Manager then the mount request is unsuccessful, in this case the Active Manager will go back and attempts to activate the next best copy based on the BCS process.

The following two tabs change content below.
Bipin is a freelance Network and System Engineer with expertise on Cisco, Juniper, Microsoft, VMware, and other technologies. You can hire him on UpWork . Follow Bipin Giri on Google+. Bipin enjoys writing articles and tutorials related to Network technologies. Some of his certifications are, MCSE:Messaging, JNCIP-SEC, JNCIS-ENT, and others.
scroll to top