CPU 總使用率百分比

Microsoft.Windows.Server.10.0.OperatingSystem.TotalCPUUtilization (UnitMonitor)

藉由 Processor Information\\% Processor Time\_Total 與 System\Processor Queue Length 效能計數器的交互關聯,以監視此伺服器的 CPU 總使用率。

Knowledge Base article:

摘要

系統處理器的 CPU Utilization (Processor Information\% Processor Time\_Total and System Queue Length) 已超過閾值。一旦超過閾值,整體系統效能可能會明顯降低,從而導致作業系統與應用程式效能不良。

設定

CPU 總使用率監視常式是一種具高度可設定性的解決方案,能讓操作員用來設定 System\Processor Queue 和 Processor\% Processor Time\_Total 效能計數器的閾值。當這兩種計數器的值超過連續樣本數的定義閾值時,監視的狀態將有所變更。在變更狀態前所必須取樣超過閾值的連續樣本數亦可自行設定。

CPU 總使用率監視常式的預設閾值包括:

參數

預設值

CPU 佇列長度閾值

15

CPU 百分比閾值

95

樣本數

3

請注意,覆寫可用來變更上述定義的任一種閾值。

原因

如果電腦在持續一段時間內的負載都相當高,可能是因下列任何狀況所致:

解決方式

若要檢視處理器相關效能計數器的最近歷程,可使用下列檢視:

啟動處理器效能檢視

若要解決此問題,系統管理員可以執行下列工作:

1. 評估伺服器上執行之每個處理序的 % Processor Utilization 計數器。您可以使用工作管理員或效能監視嵌入式管理單元來執行這項工作。請先確定哪些處理程序消耗最多資源,然後監視這些處理程序一段時間,以確定它們是否能恢復至正常的效能範圍內。若無法執行這項工作,應執行應用程式相關的診斷,以確定解決問題的最佳方式。

2. 如果確定用戶端負載隨著時間而增加,但電腦已無法再滿足需求時,請執行額外的效能監視程序,以確定基本硬體升級能否讓電腦恢復至最佳的效能範圍內。

3. 如果確定應用程式可能因產品瑕疵而處於狀況不良狀態,則可能需要重新啟動應用程式。如果問題持續發生,您可能需要連絡應用程式廠商。

Element properties:

TargetMicrosoft.Windows.Server.10.0.OperatingSystem
Parent MonitorSystem.Health.PerformanceState
CategoryPerformanceHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.Windows.Server.10.0.CPUUtilization.Monitortype
RemotableTrue
AccessibilityPublic
Alert Message
CPU 總使用率百分比過高
Processor Information\\% Processor Time\_Total 效能計數器已超過閾值。以下的值已超過閾值: {0}\% CPU 及處理器佇列長度 {1}。
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.Windows.Server.10.0.OperatingSystem.TotalCPUUtilization" Accessibility="Public" Enabled="true" Target="ServervNext!Microsoft.Windows.Server.10.0.OperatingSystem" ParentMonitorID="SystemHealth!System.Health.PerformanceState" Remotable="true" Priority="Normal" TypeID="Microsoft.Windows.Server.10.0.CPUUtilization.Monitortype" ConfirmDelivery="false">
<Category>PerformanceHealth</Category>
<AlertSettings AlertMessage="Microsoft.Windows.Server.10.0.OperatingSystem.TotalCPUUtilization.AlertMessage">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Error</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Data/Context/Property[@Name='PctUsage']$</AlertParameter1>
<AlertParameter2>$Data/Context/Property[@Name='QueueLength']$</AlertParameter2>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="OverThreshold" MonitorTypeStateID="CPUUtilizationHigh" HealthState="Error"/>
<OperationalState ID="UnderThreshold" MonitorTypeStateID="CPUUtilizationNormal" HealthState="Success"/>
</OperationalStates>
<Configuration>
<IntervalSeconds>900</IntervalSeconds>
<TimeoutSeconds>300</TimeoutSeconds>
<TargetComputerName>$Target/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</TargetComputerName>
<CPUPercentageThreshold>95</CPUPercentageThreshold>
<CPUQueueLengthThreshold>15</CPUQueueLengthThreshold>
<NumSamples>3</NumSamples>
<CounterName>% Processor Time</CounterName>
<ObjectName>Processor Information</ObjectName>
<InstanceName>_Total</InstanceName>
<AllInstances>false</AllInstances>
</Configuration>
</UnitMonitor>