Solved

Setting a "Preferred" database copy in a DAG

Posted on 2013-05-21
3
1,112 Views
Last Modified: 2013-05-23
I currently have a Microsoft Exchange 2013 deployment which has two servers in two different sites. Both servers hold the Mailbox and Client-Access-Server roles.

The two servers are both members of a Database Availability Group, and they each hold copies of a single mailbox database, the only one used by the organization.

The two sites are linked by a site-to-site VPN, but the Internet connection at Site A is 3x as fast and housed in a better facility, so as a result, I normally have the "Server A" be the Active Member.

However, any time there's a connectivity issue or anything happens at Server A (e.g. install updates and reboot), there is a switchover to Server B. It never switches back. So I have to manually go in and activate the Site A database copy whenever anything happens.

Is there a way I can specify that Site A should always be the active member whenever  possible, so that it returns to being the active member after a switchover?
0
Comment
Question by:Frosty555
3 Comments
 
LVL 42

Expert Comment

by:Amit
ID: 39185602
Switch back require a manual intervention. As you need to first find the root cause why it is switched over, fix it and fail back. Because Exchange doesn't know, if you have power outage or WAN failure etc.
0
 
LVL 2

Accepted Solution

by:
DonYoung earned 500 total points
ID: 39185658
Set the activation preferences, and run the following command on a schedule...  I recommend once a night - assuming you patch at night...

cd "\Program Files\Microsoft\Exchange Server\V14\Scripts"
.\RedistributeActiveDatabases.ps1 -DagName DAG1 -BalanceDbsByActivationPreference

Open in new window

0
 
LVL 31

Author Comment

by:Frosty555
ID: 39192347
To set it up as a scheduled task, the actual syntax for the command was:

PowerShell -noninteractive .\RedistributeActiveDatabases.ps1 -DagName DAG1 -BalanceDbsByActivationPreference -Confirm:$False

Also, replace "DAG1" with the actual name of the DAG.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read this checklist to learn more about the 15 things you should never include in an email signature.
In-place Upgrading Dirsync to Azure AD Connect
In this Micro Tutorial viewers will learn how to use Windows Server Backup to create full image of their system. Tutorial shows how to install Windows Server Backup Feature on Windows 2012R2 and how to configure scheduled Bare Metal Recovery backup.…
In this Micro Tutorial viewers will learn how to use Boot Corrector from Paragon Rescue Kit Free to identify and fix the boot problems of Windows 7/8/2012R2 etc. As an example is used Windows 2012R2 which lost its active partition flag (often happen…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question