可用性群組自動容錯移轉

Microsoft.SQLServer.2012.AlwaysOn.AutomaticFailoverReadinessRollup (DependencyMonitor)

Knowledge Base article:

摘要

此監視器會檢查可用性群組是否至少有一個已做好容錯移轉準備的次要複本。當主要複本的容錯移轉模式為自動,但是可用性群組中的次要複本都未準備進行自動容錯移轉時,監視器就會處於狀況不良的狀態並引發警示。至少有一個次要複本已做好自動容錯移轉的準備時,監視器就會處於狀況良好的狀態。

原因

可用性群組尚未準備進行自動容錯移轉。主要複本已設定為自動容錯移轉,不過次要複本尚未準備進行自動容錯移轉。設定為自動容錯移轉的次要複本可能無法使用,或者其資料同步處理狀態目前不是 SYNCHRONIZED。

解決方式

可覆寫的參數

名稱

描述

預設值

警示優先程式

定義警示優先順序。

一般

警示嚴重性

定義警示嚴重性。

錯誤

已啟用

啟用或停用該工作流程。

產生警示

定義工作流程是否會產生警示。

Element properties:

TargetMicrosoft.SQLServer.2012.AlwaysOn.AvailabilityGroup
Parent MonitorSystem.Health.AvailabilityState
AlgorithmWorstOf
Source MonitorMicrosoft.SQLServer.2012.AlwaysOn.AutomaticFailoverReadiness
RelationshipMicrosoft.SQLServer.2012.AlwaysOn.AvailabilityGroupReferencesAvailabilityGroupHealth
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
Alert Auto ResolveTrue
RemotableTrue
AccessibilityPublic
Alert Message
可用性群組尚未準備進行自動容錯移轉
可用性群組 {0} 尚未準備進行自動容錯移轉,而它已設定為自動容錯移轉

Source Code:

<DependencyMonitor ID="Microsoft.SQLServer.2012.AlwaysOn.AutomaticFailoverReadinessRollup" Accessibility="Public" Enabled="true" Target="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityGroup" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" RelationshipType="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityGroupReferencesAvailabilityGroupHealth" MemberMonitor="Microsoft.SQLServer.2012.AlwaysOn.AutomaticFailoverReadiness">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.SQLServer.2012.AlwaysOn.AutomaticFailoverReadinessAlertMessage">
<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="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityGroup"]/ClusterName$</AlertParameter2>
<AlertParameter3>$Target/Property[Type="AlwaysOnDisc!Microsoft.SQLServer.2012.AlwaysOn.AvailabilityGroup"]/PrimaryReplicaServerName$</AlertParameter3>
</AlertParameters>
</AlertSettings>
<Algorithm>WorstOf</Algorithm>
<MemberUnAvailable>Warning</MemberUnAvailable>
</DependencyMonitor>