마지막 실행 상태

Microsoft.SQLServer.Windows.Monitor.AgentJob.LastRunState (UnitMonitor)

Windows의 SQL 에이전트 작업 마지막 실행 상태 모니터입니다. SQL 에이전트 작업의 마지막 실행 상태를 모니터링합니다.
SQL Server 에이전트 Windows 서비스는 모든 버전의 SQL Server Express에서 지원되지 않습니다. 적절한 검색된 개체가 없습니다.

Knowledge Base article:

요약

SQL 에이전트 작업 마지막 실행 상태 모니터입니다. SQL 에이전트 작업의 마지막 실행 상태를 모니터링합니다.

구성

IntervalSeconds(초)의 기본값은 600입니다.

재정의 가능한 매개 변수

이름

설명

기본값

경고 우선 순위

알림 우선 순위를 정의합니다.

보통

경고 심각도

알림 심각도를 정의합니다.

경고

사용

워크플로 사용하거나 사용하지 않도록 설정합니다.

알림 생성

워크플로에서 알림을 생성하는지 여부를 정의합니다.

간격(초)

워크플로를 실행하는 반복 시간 간격(초)입니다.

600

동기화 시간

24시간 형식으로 지정된 동기화 시간입니다. 생략될 수 있습니다.

 

시간 제한(초)

여기서 지정한 시간 동안 워크플로가 실행된 후 워크플로가 닫히고 실패로 표시됩니다.

300

데이터베이스 연결 시간 제한(초)

워크플로는 지정된 기간 동안 데이터베이스에 액세스할 수 없으면 실패하며 이벤트를 등록합니다.

15

Element properties:

TargetMicrosoft.SQLServer.Windows.AgentJob
Parent MonitorSystem.Health.AvailabilityState
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityWarning
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.SQLServer.Windows.MonitorType.AgentJob.LastRunState
RemotableTrue
AccessibilityPublic
Alert Message
Windows의 MSSQL: 에이전트 작업 마지막 실행 실패
에이전트 작업 "{0}"의 마지막 실행이 실패했습니다.
인스턴스 이름: {1}
컴퓨터 이름: {2}
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.SQLServer.Windows.Monitor.AgentJob.LastRunState" Accessibility="Public" Enabled="true" Target="SqlDiscW!Microsoft.SQLServer.Windows.AgentJob" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="Microsoft.SQLServer.Windows.MonitorType.AgentJob.LastRunState" ConfirmDelivery="false">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.SQLServer.Windows.Monitor.AgentJob.LastRunState.AlertMessage">
<AlertOnState>Warning</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Warning</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/MachineName$</AlertParameter1>
<AlertParameter2>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/InstanceName$</AlertParameter2>
<AlertParameter3>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.AgentJob"]/Name$</AlertParameter3>
<AlertParameter4>$Data/Context/Property[@Name='LastMessage']$</AlertParameter4>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="LastRunSucceeded" MonitorTypeStateID="LastRunSucceeded" HealthState="Success"/>
<OperationalState ID="LastRunFailed" MonitorTypeStateID="LastRunFailed" HealthState="Warning"/>
</OperationalStates>
<Configuration>
<MachineName>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/MachineName$</MachineName>
<NetbiosComputerName>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/NetbiosComputerName$</NetbiosComputerName>
<InstanceName>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/InstanceName$</InstanceName>
<ConnectionString>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/ConnectionString$</ConnectionString>
<InstanceVersion>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/Version$</InstanceVersion>
<InstanceEdition>$Target/Host/Host/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/Edition$</InstanceEdition>
<MonitoringType>$Target/Host/Host/Property[Type="SqlDiscW!Microsoft.SQLServer.Windows.DBEngine"]/MonitoringType$</MonitoringType>
<JobName>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.AgentJob"]/Name$</JobName>
<ThresholdCountOfFails>1</ThresholdCountOfFails>
<InterpretCancelledAsFailed>false</InterpretCancelledAsFailed>
<SqlExecTimeoutSeconds>60</SqlExecTimeoutSeconds>
<SqlTimeoutSeconds>15</SqlTimeoutSeconds>
<TimeoutSeconds>300</TimeoutSeconds>
<IntervalSeconds>600</IntervalSeconds>
<SyncTime/>
</Configuration>
</UnitMonitor>