h1

Exchange 2010 SP1 Tidbits: Balancing DAG Database Copies

June 30, 2011

Exchange 2010 DAGs (Database Availability Groups) have become quite popular, and why not, it’s a simplified method for HA that requires no complex clustering configuration and allows for up to 16 different copies of a mailbox database. In small environments managing your DAG databases should be quite simple, but in a much larger organization it could become a challenge as time goes by and databases switchover or failover between mailbox servers.

Active databases might become unevenly distributed between Mailbox Servers and Administrators could use a helping hand in getting these databases evenly distributed between DAG members.

There is a new script available in Exchange 2010 SP1 that allows for balancing database copies. The script RedistributeActiveDatabases.ps1, moves databases between their passive copies with an end result of equal number of mounted databases on each member of the DAG.

According to Microsoft TechNet article: Managing Mailbox Database Copies: Exchange 2010 SP1 Help

There are two options for balancing:

  • BalanceDbsByActivationPreference script will move databases to their most preferred copy (based on Activation Preference) with no regard to Active Directory sites.
  • BalanceDbsBySiteAndActivationPreference the script moves active databases to their most preferred copy, while also attempting to balance active databases within each Active Directory site.

The following examples are taken from the same Microsoft TechNet article:

This example shows the current database distribution for a DAG, including preference count list.

RedistributeActiveDatabases.ps1 -DagName DAG1 -ShowDatabaseDistributionByServer | Format-Table

This example redistributes and balances the active mailbox database copies in a DAG using activation preference without prompting for input.

RedistributeActiveDatabases.ps1 -DagName DAG1 -BalanceDbsByActivationPreference -Confirm:$False

This example redistributes and balances the active mailbox database copies in a DAG using activation preference, and produces a summary of the distribution.

RedistributeActiveDatabases.ps1 -DagName DAG1 -BalanceDbsByActivationPreference -ShowFinalDatabaseDistribution


Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: