Availability Group Online (rollup)

Microsoft.SQLServer.Core.Rollup.AvailabilityGroup.AvailabilityGroupOnline (AggregateMonitor)

This monitor checks the online or offline state of Availability Group. The monitor is in unhealthy state and alert is raised when the Availability Group’s cluster resource is offline or the Availability Group does not have a primary replica. The monitor state is healthy when the cluster resource of Availability Group is online and the Availability Group has a primary replica. This monitor is an aggregate (rollup) monitor.

Knowledge Base article:

Summary

This monitor checks the online or offline state of Availability Group. The monitor is unhealthy and alert is raised when the Availability Group’s cluster resource is offline or the Availability Group does not have a primary replica. The monitor state is healthy when the cluster resource of Availability Group is online and the Availability Group has a primary replica.

Causes

The Availability Group is offline, and is unavailable. This issue can be caused by a failure in the server instance that hosts the primary replica or by the WSFC Availability Group resource going offline.

Resolutions

Overridable Parameters

Name

Description

Default Value

Alert Priority

Defines Alert Priority.

Normal

Alert Severity

Defines Alert Severity.

Error

Enabled

Enables or disables the workflow.

Yes

Generates Alerts

Defines whether the workflow generates an Alert.

Yes

Element properties:

TargetMicrosoft.SQLServer.Core.AvailabilityGroup
Parent MonitorSystem.Health.AvailabilityState
AlgorithmWorstOf
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
Alert Auto ResolveTrue
RemotableTrue
AccessibilityPublic
Alert Message
MSSQL: Availability Group is offline
The Availability Group {0} is offline and it is not available.
Cluster Name: {1}
Primary Replica: {2}

Source Code:

<AggregateMonitor ID="Microsoft.SQLServer.Core.Rollup.AvailabilityGroup.AvailabilityGroupOnline" Accessibility="Public" Enabled="true" Target="Microsoft.SQLServer.Core.AvailabilityGroup" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.SQLServer.Core.Rollup.AvailabilityGroup.AvailabilityGroupOnline.AlertMessage">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Error</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Property[Type="System!System.Entity"]/DisplayName$</AlertParameter1>
<AlertParameter2>$Target/Property[Type="Microsoft.SQLServer.Core.AvailabilityGroup"]/ClusterName$</AlertParameter2>
<AlertParameter3>$Target/Property[Type="Microsoft.SQLServer.Core.AvailabilityGroup"]/PrimaryReplicaServerName$</AlertParameter3>
</AlertParameters>
</AlertSettings>
<Algorithm>WorstOf</Algorithm>
</AggregateMonitor>