Product Version Compliance

Microsoft.SQLServer.Linux.Monitor.DBEngine.ServicePackLevel (UnitMonitor)

This monitor checks the product version number of the current SQL Server instance to determine the currently installed Cumulative Update.

Knowledge Base article:

Summary

This monitor checks the product version number of the current SQL Server instance to determine the currently installed Cumulative Update. An alert will be raised if the current product version number is lower than the default value set in the monitor properties. As a new version of the management pack is released, the default value is updated to correspond to a product version containing the most recent SQL Server Cumulative Update that is available publicly. If necessary, the default value can also be changed via the overrides.

Note that a value for the "Minimal product version number for SQL Server" override should be set for objects grouped according to the SQL Server version; at that, a created group should contain instances of the same major version.

The default values are as follows:

Causes

An unhealthy state of this monitor is caused by product version number of the SQL instance being outdated.

Resolutions

This issue may be resolved by applying the latest update to SQL Server.

Alternatively, if the current settings are valid within your environment:

External

Latest updates for Microsoft SQL Server

Overridable Parameters

Name

Description

Default Value

Alert Priority

Defines Alert Priority.

Normal

Alert Severity

Defines Alert Severity.

Match monitor’s health

Enabled

Enables or disables the workflow.

Yes

Generates Alerts

Defines whether the workflow generates an Alert.

Yes

Interval (seconds)

The recurring interval of time in seconds in which to run the workflow.

43200

Minimal product version number for SQL Server

The number of the minimal product version containing the required SQL Server CU.

 

Synchronization Time

The synchronization time specified by using a 24-hour format. May be omitted.

 

Timeout (seconds)

Specifies the time the workflow is allowed to run before being closed and marked as failed.

200

Timeout for query execution (seconds)

The workflow will fail and register an event, if the query execution takes longer than the specified period.

60

Timeout for database connection (seconds)

The workflow will fail and register an event, if it cannot access the database during the specified period.

15

Element properties:

TargetMicrosoft.SQLServer.Linux.DBEngine
Parent MonitorSystem.Health.ConfigurationState
CategoryConfigurationHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityMatchMonitorHealth
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.SQLServer.Linux.MonitorType.DBEngine.ServicePackLevel
RemotableTrue
AccessibilityPublic
Alert Message
MSSQL on Linux: Product version compliance

The product version number of the SQL Server instance "{1}" on computer "{0}" is outdated
Expected version: {2}, actual version: {3}
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.SQLServer.Linux.Monitor.DBEngine.ServicePackLevel" Accessibility="Public" Enabled="true" Target="SqlDiscL!Microsoft.SQLServer.Linux.DBEngine" ParentMonitorID="Health!System.Health.ConfigurationState" Remotable="true" Priority="Normal" TypeID="Microsoft.SQLServer.Linux.MonitorType.DBEngine.ServicePackLevel" ConfirmDelivery="false">
<Category>ConfigurationHealth</Category>
<AlertSettings AlertMessage="Microsoft.SQLServer.Linux.Monitor.DBEngine.ServicePackLevel.AlertMessage">
<AlertOnState>Warning</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>MatchMonitorHealth</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/MachineName$</AlertParameter1>
<AlertParameter2>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/InstanceName$</AlertParameter2>
<AlertParameter3>$Data/Context/Property[@Name='ExpectedVersion']$</AlertParameter3>
<AlertParameter4>$Data/Context/Property[@Name='ActualVersion']$</AlertParameter4>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="SPCompliant" MonitorTypeStateID="ValueGood" HealthState="Success"/>
<OperationalState ID="SPNotCompliant" MonitorTypeStateID="ValueBad" HealthState="Warning"/>
</OperationalStates>
<Configuration>
<MachineName>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/MachineName$</MachineName>
<NetbiosComputerName>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/NetbiosComputerName$</NetbiosComputerName>
<InstanceName>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/InstanceName$</InstanceName>
<ConnectionString>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/ConnectionString$</ConnectionString>
<InstanceVersion>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/Version$</InstanceVersion>
<InstanceEdition>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/Edition$</InstanceEdition>
<IntervalSeconds>43200</IntervalSeconds>
<SyncTime/>
<TimeoutSeconds>200</TimeoutSeconds>
<SqlExecTimeoutSeconds>60</SqlExecTimeoutSeconds>
<SqlTimeoutSeconds>15</SqlTimeoutSeconds>
<GoodValue/>
</Configuration>
</UnitMonitor>