This monitor checks the state of role of availability replica. The monitor is in unhealthy state when the availability replica’s role is not primary or secondary. The monitor is healthy otherwise.
The role of this availability replica is unhealthy. The replica does not have either the primary or secondary role.
Name | Description | Default Value |
Enabled | Enables or disables the workflow. | Yes |
Generates Alerts | Defines whether the workflow generates an Alert. | No |
Interval (seconds) | The recurring interval of time in seconds in which to run the workflow. | 900 |
Policy Name |
| $Target/Property[Type="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityReplica"]/AvailabilityGroupName$-$Target/Property[Type="System!System.Entity"]/DisplayName$-AlwaysOnArRoleHealthPolicy |
Timeout (seconds) | Specifies the time the workflow is allowed to run before being closed and marked as failed. | 300 |
Target | Microsoft.SQLServer.2012.AlwaysOn.AvailabilityReplica |
Parent Monitor | System.Health.AvailabilityState |
Category | AvailabilityHealth |
Enabled | True |
Alert Generate | False |
Alert Auto Resolve | False |
Monitor Type | Microsoft.SQLServer.2012.AlwaysOn.SystemPolicyScriptMonitorType |
Remotable | True |
Accessibility | Public |
RunAs | Microsoft.SQLServer.2012.AlwaysOn.MonitoringAccount |
<UnitMonitor ID="Microsoft.SQLServer.2012.AlwaysOn.RoleOfAvailabilityReplicaIsHealthy" RunAs="Microsoft.SQLServer.2012.AlwaysOn.MonitoringAccount" TypeID="Microsoft.SQLServer.2012.AlwaysOn.SystemPolicyScriptMonitorType" Accessibility="Public" Enabled="true" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Target="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityReplica" Priority="Normal">
<Category>AvailabilityHealth</Category>
<OperationalStates>
<OperationalState ID="Success" MonitorTypeStateID="HealthState" HealthState="Success"/>
<OperationalState ID="Critical" MonitorTypeStateID="ErrorState" HealthState="Error"/>
</OperationalStates>
<Configuration>
<Interval>900</Interval>
<TimeoutSeconds>300</TimeoutSeconds>
<PolicyName>$Target/Property[Type="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityReplica"]/AvailabilityGroupName$-$Target/Property[Type="System!System.Entity"]/DisplayName$-AlwaysOnArRoleHealthPolicy</PolicyName>
<InstanceName>$Target/Property[Type="System!System.Entity"]/DisplayName$</InstanceName>
</Configuration>
</UnitMonitor>