Detects SQL Server DB Engine restart. Note: This rule is disabled by default. Please use overrides to enable it when necessary.
This rule detects restart of SQL Server.
This rule detects that SQL DB Engine service was in "Stopped" state during some short period and turned back to “Running” state after that. The allowed duration of unavailability is defined by "Unavailable Time" parameter and could be overridden. By default, this value is 900 seconds (15 minutes).
Name | Description | Default Value |
Enabled | Enables or disables the workflow. | No |
Priority | Defines Alert Priority. | 1 |
Severity | Defines Alert Severity. | 1 |
Timeout (seconds) | Specifies the time the workflow is allowed to run before being closed and marked as failed. | 300 |
Timeout for database connection (seconds) | The workflow will fail and register an event, if it cannot access the database during the specified period. | 15 |
Unavailable Time (seconds) | The workflow will try to catch a service start event during this time frame, after event service stops. | 900 |
Target | Microsoft.SQLServer.Linux.DBEngine | ||
Category | AvailabilityHealth | ||
Enabled | False | ||
Alert Generate | True | ||
Alert Severity | Warning | ||
Alert Priority | Normal | ||
Remotable | True | ||
Alert Message |
|
ID | Module Type | TypeId | RunAs |
---|---|---|---|
ServiceRestart | DataSource | Microsoft.SQLServer.Linux.DataSource.DBEngineServiceRestart | Default |
GenerateAlert | WriteAction | System.Health.GenerateAlert | Default |
<Rule ID="Microsoft.SQLServer.Linux.EventRule.DBEngine.ServiceRestart" Enabled="false" Target="SqlDiscL!Microsoft.SQLServer.Linux.DBEngine" ConfirmDelivery="true" Remotable="true" Priority="Normal" DiscardLevel="100">
<Category>AvailabilityHealth</Category>
<DataSources>
<DataSource ID="ServiceRestart" TypeID="Microsoft.SQLServer.Linux.DataSource.DBEngineServiceRestart">
<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>
<TimeoutSeconds>300</TimeoutSeconds>
<SqlTimeoutSeconds>15</SqlTimeoutSeconds>
<CorrelatorInterval>900</CorrelatorInterval>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="GenerateAlert" TypeID="Health!System.Health.GenerateAlert">
<Priority>1</Priority>
<Severity>1</Severity>
<AlertMessageId>$MPElement[Name="Microsoft.SQLServer.Linux.EventRule.DBEngine.ServiceRestart.AlertMessage"]$</AlertMessageId>
<AlertParameters>
<AlertParameter1>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/InstanceName$</AlertParameter1>
<AlertParameter2>$Target/Property[Type="SqlCoreLib!Microsoft.SQLServer.Core.DBEngine"]/MachineName$</AlertParameter2>
</AlertParameters>
<Suppression>
<SuppressionValue/>
</Suppression>
</WriteAction>
</WriteActions>
</Rule>