I have configured Distributed AG from DC1 to DC2 (SQL 2017 Ent edition with CU22 version)
DC1- DB1, DB2 and DC2-DB3, DB4
-
I have restarted DC1-DB1 SQL services, after restart DC1-DB2 should be primary. But still DC1-DB2 showing as secondary. Is this is the expected behaviour?
-
I have restarted DC1-DB2 SQL services, nothing happen – still DC1-DB1 is primary. Is this is the expected behaviour?
DC1 AG configurations:
Best Answer
The exact similar question was asked on new Microsoft Q and A Site. I created a 2 node WSFC with AG configured for SQL Server databases. To simply put WSFC did not initiated a failover because the parameter
Failure-Condition Level
isdefault 3
. And as per Microsoft official document Configure a flexible automatic failover policy for an Always On availability group for a SQL Server restart to trigger a failover you needFailure-Condition Level
=1This can be changed via Powershell, TSQL or from cluster GUI. One below shows value in cluster GUI