5

This fall we will be powering down the whole data center to replace a defective power module. There is no DR site to move anything to, everything last bit of the company resides in one DC at one location. What is the best way to shut down a 2 node availability group? Should I remove the databases from the AG then power off the servers? When bringing the servers online after the power work is done. Should I have the share witness server up first, then the primary server and second server last? Then re-add the databases to the AG? We run Windows 2008 R2, and SQL Server Enterprise 2012 core edition in a VMware environment.

2 Answers 2

5

No need to touch the AGs. You should have full set of database backups on a USB external drive or on Azure Blob Storage before you shut down the datacenter.

Just shut down the secondary node first, then the primary. Bring them back up in the reverse order. Boot up your domain controller VMs first, then any other supporting infrastructure, like the VM hosting the FSW. When you bring the VM hosting the primary replica online it should establish quorum and come online.

1
  • A must add make sure everything is green in availability group dashboard before you shutdown. If not, first resolve any issues which can create problem after AG comes online after shutdown.
    – Shanky
    Commented Jul 18, 2018 at 7:24
0

I would make sure that before shutdown, all groups are primary on the same machine. Then shutdown the secondary replica first. Once those are shutdown, bring down the primary replica.

When things are ready to be brought back up, bring up the primary, and then the secondary. Run through your normal daily check process against all SQL instances to ensure that things are looking good. Run some smoke tests against the listeners to make sure things are operating as expected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.