逻辑 CPU DPC 时间百分比

Microsoft.Windows.Server.10.0.LogicalProcessor.PercentDPCTime (UnitMonitor)

监视 DPC 时间百分比

Knowledge Base article:

摘要

逻辑处理器的 DPC 时间百分比(Processor\% DPC Time)超过了阈值。总体系统性能显著降低,并将导致操作系统和应用程序性能较差。

DPC 时间百分比(%)是逻辑处理器用于接收和服务延迟的过程调用(DPC)的时间百分比。DPC 是运行优先级低于标准中断的中断。如果 DPC 时间百分比(%)持续较高,则可能存在逻辑处理器瓶颈或者与应用程序或硬件相关的问题,该问题可能导致总体系统性能显著降低。

原因

下列一个或多个原因可能会造成高 DPC 时间百分比(%)值:

解决方法

根据下述过程确定高 DPC 的根本原因。

观察用于服务中断和 DPC 的处理器时间的比例。为此,使用系统监视器监视下列计数器:

将 % Interrupt Time 和 % DPC Time 计数器的值与每个处理器实例的 Processor\% Processor Time 比较。

如果逻辑处理器实例的处理器时间百分比(%)持续大于 85%,并且其中 15% 以上的时间用于服务中断和/或 DPC,则处理器可能是性能瓶颈的根源。可通过为计算机升级或添加附加处理器来解决瓶颈问题。

如果逻辑处理器的处理器时间百分比(%)持续小于 85%,并且其中 15% 以上的时间用于服务中断和/或 DPC,性能问题可能由应用程序或硬件相关问题造成。

如果硬件设备是根本原因,管理员将发现 DPC 时间百分比(%)可能在很短的时间内显著增加。安装新硬件或升级驱动程序时,通常发生这种情况。如果管理员可以确定问题为硬件或设备驱动程序问题,可与供应商联系以进行解决。

如果你管理的是一个多处理器系统,无法平衡地分布中断,通常,通过添加网络适配器,使每个处理器都有一个适配器,即可改善处理器工作负荷的分布。通常,只有在需要提高系统吞吐量时才添加适配器。与其他附加硬件一样,网络适配器也有一些内部开销。但是,如果某个处理器几乎始终处于活动状态(即如果处理器信息: 处理器时间百分比 = 100),并且一半以上的时间用于服务 DPC (如果处理器信息: DPC 时间百分比 > 50),则只要可用网络带宽尚未达到饱和,添加适配器可能会提高系统性能。

如果应用程序是根本原因,将发现 DPC 可能被应用程序阻塞,因为应用程序发出的调用需要大量时间才能完成。在此期间,DPC 将被阻塞并排队。若要确定哪个应用程序是根本原因,你必须运行高级性能、跟踪及诊断以确定造成性能问题的具体应用程序。

Element properties:

TargetMicrosoft.Windows.Server.10.0.LogicalProcessor
Parent MonitorSystem.Health.PerformanceState
CategoryPerformanceHealth
EnabledFalse
Instance NameProcessor
Counter Name\% DPC Time
Frequency120
Alert GenerateFalse
Alert Auto ResolveTrue
Monitor TypeSystem.Performance.ConsecutiveSamplesThreshold
RemotableTrue
AccessibilityPublic
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.Windows.Server.10.0.LogicalProcessor.PercentDPCTime" Accessibility="Public" Enabled="false" Target="ServervNext!Microsoft.Windows.Server.10.0.LogicalProcessor" ParentMonitorID="SystemHealth!System.Health.PerformanceState" Remotable="true" Priority="Normal" TypeID="SystemPerf!System.Performance.ConsecutiveSamplesThreshold" ConfirmDelivery="false">
<Category>PerformanceHealth</Category>
<OperationalStates>
<OperationalState ID="OverThreshold" MonitorTypeStateID="ConditionTrue" HealthState="Error"/>
<OperationalState ID="UnderThreshold" MonitorTypeStateID="ConditionFalse" HealthState="Success"/>
</OperationalStates>
<Configuration>
<ComputerName>$Target/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</ComputerName>
<CounterName>% DPC Time</CounterName>
<ObjectName>Processor</ObjectName>
<InstanceName>$Target/Property[Type="ServervNext!Microsoft.Windows.Server.10.0.LogicalProcessor"]/PerfmonInstance$</InstanceName>
<Frequency>120</Frequency>
<Threshold>15</Threshold>
<Direction>greaterequal</Direction>
<NumSamples>5</NumSamples>
</Configuration>
</UnitMonitor>