diff --git a/samples/manage/sql-assessment-api/DefaultRuleset.csv b/samples/manage/sql-assessment-api/DefaultRuleset.csv index 8e6d5a8b..42adb91d 100644 --- a/samples/manage/sql-assessment-api/DefaultRuleset.csv +++ b/samples/manage/sql-assessment-api/DefaultRuleset.csv @@ -193,15 +193,15 @@ "MaxDopFewNumaLess16","definition","TRUE","Low","MAXDOP set in accordance with CPU count","Update MAXDOP configuration option value: @{max_dop}. It should not exceed the number of logical processors per NUMA node","DefaultRuleset, MaxDOP, Performance, Configuration, NUMA, CPU","The Microsoft SQL Server max degree of parallelism (MAXDOP) configuration option controls the number of processors that are used for the execution of a query in a parallel plan. This option determines the number of threads that are used for the query plan operators that perform the work in parallel. Depending on whether SQL Server is set up on a symmetric multiprocessing (SMP) computer, a non-uniform memory access (NUMA) computer, or hyperthreading-enabled processors, the max degree of parallelism option should be configured appropriately.","https://support.microsoft.com/kb/2806535","Server","Windows Linux",,"SqlServer","[13.0,)",,, "MaxDopFewNumaOver16","definition","TRUE","Low","MAXDOP set in accordance to CPU count","Update MAXDOP configuration option value: @{max_dop}. It should be half the number of logical processors per NUMA node with maximum value of 16","DefaultRuleset, MaxDOP, Performance, Configuration, NUMA, CPU","The Microsoft SQL Server max degree of parallelism (MAXDOP) configuration option controls the number of processors that are used for the execution of a query in a parallel plan. This option determines the number of threads that are used for the query plan operators that perform the work in parallel. Depending on whether SQL Server is set up on a symmetric multiprocessing (SMP) computer, a non-uniform memory access (NUMA) computer, or hyperthreading-enabled processors, the max degree of parallelism option should be configured appropriately.","https://support.microsoft.com/kb/2806535","Server","Windows Linux",,"SqlServer","[13.0,)",,, "MaxDopFewNumaOver8","definition","TRUE","Medium","MAXDOP set in accordance with CPU count","Update MAXDOP configuration option value: @{max_dop}. It should be equal to 8","DefaultRuleset, MaxDOP, Performance, Configuration, NUMA, CPU","The Microsoft SQL Server max degree of parallelism (MAXDOP) configuration option controls the number of processors that are used for the execution of a query in a parallel plan. This option determines the number of threads that are used for the query plan operators that perform the work in parallel. Depending on whether SQL Server is set up on a symmetric multiprocessing (SMP) computer, a non-uniform memory access (NUMA) computer, or hyperthreading-enabled processors, the max degree of parallelism option should be configured appropriately.","https://support.microsoft.com/kb/2806535","Server","Windows",,"SqlServer","[11.0, 13.0)",,, -"MaxMemory","definition","TRUE","Low","Max allowed memory ","Set 'max server memory' value to @{recommended:N0} MB or less to avoid detrimental memory pressure. Current 'max server memory' value is @{max_server_memory:N0}, which is greater than recommended","DefaultRuleset, Memory, Performance, MaxMemory","Setting the 'max server memory' value too high can cause a single instance of SQL Server to compete for memory with other SQL Server instances hosted on the same machine. However, setting this value too low could cause significant memory pressure and performance problems.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options","Server","Windows Linux",,"SqlServer","[11.0,)",,,"2147483647" +"MaxMemory","definition","TRUE","Low","Max allowed memory ","Set 'max server memory (MB)' value to @{recommended:N0} MB or less to avoid detrimental memory pressure. Current 'max server memory (MB)' value is @{max_server_memory:N0}, which is greater than recommended","DefaultRuleset, Memory, Performance, MaxMemory","Setting the 'max server memory (MB)' value too high can cause a single instance of SQL Server to compete for memory with other SQL Server instances hosted on the same machine. However, setting this value too low could cause significant memory pressure and performance problems.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options","Server","Windows Linux",,"SqlServer","[11.0,)",,,"2147483647" "MaxMemory","override","TRUE","Low",,,"",,,,,,"Express",,,,"1410" "MaxMemory","override","TRUE","Low",,,"",,,,,,"Standard",,,,"131072" -"MaxMemorySystem","definition","TRUE","Low","Max server memory exceeds system memory","Set 'max server memory' to @{recommended:N0} MB or less to avoid detrimental memory pressure. System memory of @{sysmem:N0} MB is not sufficient for current 'max server memory' setting of @{max_server_memory:N0} MB","DefaultRuleset, Memory, Performance, MaxMemory","Setting the 'max server memory' value higher than system memory can cause SQL Server to compete for memory with the operating system and processes running on the same machine.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options","Server","Windows Linux",,"SqlServer","[11.0,)",,,"2147483647" +"MaxMemorySystem","definition","TRUE","Low","Max server memory exceeds system memory","Set 'max server memory (MB)' to @{recommended:N0} MB or less to avoid detrimental memory pressure. System memory of @{sysmem:N0} MB is not sufficient for current 'max server memory (MB)' setting of @{max_server_memory:N0} MB","DefaultRuleset, Memory, Performance, MaxMemory","Setting the 'max server memory (MB)' value higher than system memory can cause SQL Server to compete for memory with the operating system and processes running on the same machine.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options","Server","Windows Linux",,"SqlServer","[11.0,)",,,"2147483647" "MaxMemorySystem","override","TRUE","Low",,,"",,,,,,"Express",,,,"1410" "MaxMemorySystem","override","TRUE","Low",,,"",,,,,,"Standard",,,,"131072" "MinMemoryPerQuery","definition","TRUE","Low","Option 'min memory per query' set to default","Set 'min memory per query' option to @{recommended_min_memory_per_query} KB. Current value is '@{min_memory_per_query}'","DefaultRuleset, Configuration, Memory, Performance","The min memory per query option specifies the minimum amount of memory (in kilobytes) that will be allocated for the execution of a query. This is also known as the minimum memory grant. The default value is 1,024 KB. Do not set the min memory per query server configuration option too high, especially on very busy systems, because the query has to wait1 until it can secure the minimum memory requested, or until the value specified in the query wait server configuration option is exceeded. If more memory is available than the specified minimum value required to execute the query, the query is allowed to make use of the additional memory, provided that the memory can be used effectively by the query.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-min-memory-per-query-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, "NetworkPacketSize","definition","TRUE","Low","Option 'network packet size' set to default","Set 'network packet size' option to @{recommended_network_packet_size} bytes. Current value is @{network_packet_size}","DefaultRuleset, Configuration, Network","The 'network packet size' option sets the packet size (in bytes) that is used across the whole network. Packets are the fixed-size chunks of data that transfer requests and results between clients and servers. The default packet size is 4096 bytes.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-network-packet-size-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, -"NtfsBlockSizeNotFormatted","definition","TRUE","Low","NTFS block size in volumes with database files <> 64KB","Set allocation unit size on volume '@{volume_mount_point}' to 64 KB. Current size is @{Output.BlockSize} bytes","DefaultRuleset, Performance, Configuration, NTFS","A drive can be formatted with different sizes ranging from 512 bytes to 64K sizes with the default being 4KB (4096 bytes). This setting is also called as “Bytes Per Cluster”. The atomic unit of storage in SQL Server is a page which is 8KB in size. Extents are groups of eight 8 KB pages that are physically contiguous to each other for a total of 64 KB. SQL Server uses extents to store data. Hence, on a SQL Server machine the NTFS Allocation unit size hosting SQL database files (Including tempdb files) should be 64 KB.","https://docs.microsoft.com/archive/blogs/docast/operating-system-best-practice-configurations-for-sql-server","Server","Windows",,"SqlServer","[11.0,)",,, +"NtfsBlockSizeNotFormatted","definition","TRUE","Low","NTFS block size in volumes with database files <> 64KB","Set allocation unit size on volume @{volume_mount_point} to 64 KB. Current size is @{Output.BlockSize} bytes","DefaultRuleset, Performance, Configuration, NTFS","A drive can be formatted with different sizes ranging from 512 bytes to 64 KB sizes with the default being 4 KB (4096 bytes). This setting is also called as “Bytes Per Cluster”. The atomic unit of storage in SQL Server is a page which is 8KB in size. Extents are groups of eight 8 KB pages that are physically contiguous to each other for a total of 64 KB. SQL Server uses extents to store data. Hence, on a SQL Server machine the NTFS Allocation unit size hosting SQL database files (Including tempdb files) should be 64 KB.","https://docs.microsoft.com/archive/blogs/docast/operating-system-best-practice-configurations-for-sql-server","Server","Windows",,"SqlServer","[11.0,)",,, "NtfsBlockSizeNotFormatted","override","TRUE","Medium",,,"",,,,,"AzureVm",,,,, "OlapSvcAccSame","definition","TRUE","Low","'Analysis Services' and 'SQL Server Database Engine' use same account","Use different accounts for the 'Analysis Services' service and the 'SQL Server Database Engine' service. Now both services use '@{attr::service::MSOLAP.account}' account","DefaultRuleset, Configuration","Running the 'Analysis Services' service under the same account as the 'SQL Server Database Engine' service is not recommended.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-windows-service-accounts-and-permissions","Server","Windows",,"SqlServer","[11.0,)",,, "OlapSvcStoped","definition","TRUE","Low","'Analysis Services' service is stopped","Run 'Analysis Services' service","DefaultRuleset, Configuration","The 'Analysis Services' service provides online analytical processing (OLAP) and data mining functionality for business intelligence applications.","https://docs.microsoft.com/sql/database-engine/configure-windows/manage-the-database-engine-services","Server","Windows",,"SqlServer","[11.0,)",,, @@ -224,7 +224,7 @@ "SqlSvcAccNotSupported","definition","TRUE","Low","'SQL Server Database Engine' service uses not supported account","Use another account to run 'SQL Server Database Engine' service. Current account '@{attr::service::MSSQL.account}' is not supported","DefaultRuleset, Configuration","Running the 'SQL Server Database Engine' service under 'NT AUTHORITY\LOCALSERVICE', 'NT AUTHORITY\SYSTEM' or 'NT AUTHORITY\NETWORKSERVICE' accounts is not supported.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-windows-service-accounts-and-permissions","Server","Windows",,"SqlServer","[11.0,)",,, "ThreadExhaustionCPUBound","definition","TRUE","Low","Worker thread exhaustion on CPU-bound system","Possible worker thread exhaustion (schedulers work queue count is '@{schedulers_work_queue_count}'). Overall runnable tasks count is '@{overall_runnable_tasks_count}' (> 2), indicating the server might be CPU-bound. Configured workers is '@{max_workers_count}'","DefaultRuleset, Performance","Consider overall runnable tasks count and schedulers work queue count.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, "ThreadExhaustionNotCPUBound","definition","TRUE","Low","Possible worker thread exhaustion on non-CPU-bound system","Possible worker thread exhaustion (schedulers work queue count is '@{schedulers_work_queue_count}'). Because overall runnable tasks count is '@{overall_runnable_tasks_count}' (<= 2), indicating the server might not be CPU bound, there might be room to increase max_worker_threads (configured workers is '@{max_workers_count}')","DefaultRuleset, Performance","Consider overall runnable tasks count and schedulers work queue count.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, -"ThresholdForParallelism","definition","TRUE","Medium","Option 'cost threshold for parallelism' set to default","Set 'cost threshold for parallelism' option to @{default_cost_parallel}. Current value is @{cost_threshold_for_parallelism}","DefaultRuleset, Configuration, Performance","The 'cost threshold for parallelism' option specifies the threshold at which SQL Server creates and runs parallel plans for queries. SQL Server creates and runs a parallel plan for a query only when the estimated cost to run a serial plan for the same query is higher than the value set in the cost threshold for parallelism. The cost refers to an estimated cost required to run the serial plan on a specific hardware configuration and is not a unit of time. The 'cost threshold for parallelism' option can be set to any value from 0 through 32767. The default value is 5.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-cost-threshold-for-parallelism-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, +"ThresholdForParallelism","definition","TRUE","Information","Non-default value for 'cost threshold for parallelism' option","Review non-default value @{cost_threshold_for_parallelism} for the 'cost threshold for parallelism' option","DefaultRuleset, Configuration, Performance","The 'cost threshold for parallelism' option specifies the threshold at which SQL Server creates and runs parallel plans for queries. SQL Server creates and runs a parallel plan for a query only when the estimated cost to run a serial plan for the same query is higher than the value set in the cost threshold for parallelism. The cost refers to an estimated cost required to run the serial plan on a specific hardware configuration and is not a unit of time. The 'cost threshold for parallelism' option can be set to any value from 0 through 32767. The default value is 5.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-cost-threshold-for-parallelism-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, "WorkerThreadsLargeX64","definition","TRUE","Low","Option 'max worker threads' set to recommended value on x64 system","Reconfigure 'max worker threads' option parameter. Current value (@{max_worker_threads}) is higher than recommended for x64 system (@{recommended_max_worker_threads})","DefaultRuleset, Configuration, Performance, CPU","The max worker threads option configures the number of worker threads that are available to SQL Server processes. The default value for max worker threads is 0. This enables SQL Server to automatically configure the number of worker threads at startup.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option","Server","Windows",,"SqlServer","[11.0,)",,, "WorkerThreadsLargeX86","definition","TRUE","Low","Option 'max worker threads' set to recommended value on x86 system","Reconfigure 'max worker threads' option. Current value (@{max_worker_threads}) is higher than recommended for x86 system (@{recommended_max_worker_threads})","DefaultRuleset, Configuration, Performance, CPU","The max worker threads option configures the number of worker threads that are available to SQL Server processes. The default value for max worker threads is 0. This enables SQL Server to automatically configure the number of worker threads at startup.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option","Server","Windows",,"SqlServer","[11.0,)",,, "XpCmdShellOn","definition","TRUE","Low","Option 'xp_cmdshell' is disabled","Disable 'xp_cmdshell' as it exposes to security risks","DefaultRuleset, Configuration","The xp_cmdshell option is a SQL Server configuration option that enables system administrators to control whether the xp_cmdshell extended stored procedure can be executed on a system. By default, the xp_cmdshell option is disabled on new installations. ","https://docs.microsoft.com/sql/database-engine/configure-windows/xp-cmdshell-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, @@ -234,6 +234,7 @@ "Affinity64Mask","definition","TRUE","Low","Non-default value for 'affinity64 mask' option","Review non-default value @{affinity64_mask} for the 'affinity64 mask' option as it will be removed in a future version","DefaultRuleset, Performance, Configuration","The 'affinity64 mask' binds processors to specific threads, similar to the 'affinity mask' option. Use 'affinity mask' to bind the first 32 processors, and use 'affinity64 mask' to bind the remaining processors.","https://docs.microsoft.com/sql/database-engine/configure-windows/affinity64-mask-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AffinityIOMask","definition","TRUE","Information","Non-default value for 'affinity I/O mask' option","Review non-default value @{affinity_io_mask} for the 'affinity I/O mask' option","DefaultRuleset, Performance, Configuration","In a multi-processor system, the 'affinity I/O mask' option binds SQL Server disk I/O to a specified subset of CPUs.","https://docs.microsoft.com/sql/database-engine/configure-windows/affinity-input-output-mask-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AffinityMask","definition","TRUE","Low","Non-default value for 'affinity mask' option","Review non-default value @{affinity_mask} for the 'affinity64 mask' option as it will be removed in a future version","DefaultRuleset, Performance, Configuration","In a multi-processor system, the 'affinity mask' option is used to assign certain CPUs to an instance of SQL Server. When the 'affinity mask' is at its default value of 0, the instance of SQL Server can use all processors in the system for its threads. Setting the 'affinity mask' to a non-default value, restricts SQL Server to using only the assigned CPUs.","https://docs.microsoft.com/sql/database-engine/configure-windows/affinity-mask-server-configuration-option","Server","Windows Linux",,"SqlServer","[11.0,)",,, +"AGCount","definition","TRUE","Information","Availability database count","Review the number of availability databases (@{database_id})","DefaultRuleset, Performance","The number of databases and availability groups hosted on a single computer (virtual or physical) depends on the hardware and workload. There is no enforced software boundary. However, having more than 100 databases on a single production computer may lead to performance issues, dependent on the workload of the databases.","https://learn.microsoft.com/sql/database-engine/availability-groups/windows/prereqs-restrictions-recommendations-always-on-availability","Server","Windows Linux",,"SqlServer","[11.0,)",,"100", "AGDbDisjoined","definition","TRUE","Low","Availability database joined state","Join database '@{databaseName}' to availability group '@{ag_name}' on secondary replica '@{ag_replica_server}'","DefaultRuleset, AlwaysOn","To add a database to an availability group, the database must be an online, read-write database that exists on the server instance that hosts the primary replica. When you add a database, it joins the availability group as a primary database. No corresponding secondary database exists until backups of the new primary database are restored to the server instance that hosts the secondary replica. The new secondary database is in the RESTORING state until it is joined to the availability group. Joining places the secondary database into the ONLINE state and initiates data synchronization with the corresponding primary database.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/join-a-secondary-database-to-an-availability-group-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AGEndpointEncryption","definition","TRUE","Low","Database mirroring endpoint encryption","Configure data encryption on endpoint '@{endpoint_name}'","","By default, a database mirroring endpoint requires encryption of data sent over mirroring connections. In this case, the endpoint can connect only to endpoints that also use encryption. Unless you can guarantee that your network is secure, we recommend that you require encryption for your database mirroring connections.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/prereqs-restrictions-recommendations-always-on-availability","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AgentXPs","definition","TRUE","Information","Option 'Agent XPs' is disabled","Enable 'Agent XPs' option","DefaultRuleset, Configuration","The 'Agent XPs' option enables the SQL Server Agent extended stored procedures. When this option is disabled, the SQL Server Agent node is not available in SQL Server Management Studio Object Explorer.","https://docs.microsoft.com/sql/database-engine/configure-windows/agent-xps-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, @@ -242,73 +243,213 @@ "AGIsFailoverReady","definition","TRUE","Low","Availability database automatic failover readiness","Database '@{databaseName}' in availability group '@{ag_name}' is not ready for automatic failover. Synchronize database on secondary replica '@{ag_replica_server}'","DefaultRuleset, AlwaysOn","Within the context of an availability group, the primary role and secondary role of availability replicas are typically interchangeable in a process known as failover. During the failover, a qualified secondary replica takes over the primary role, recovers its databases, and brings them online as the new primary databases. An automatic failover causes a qualified secondary replica to automatically transition to the primary role after the primary replica becomes unavailable.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/failover-and-failover-modes-always-on-availability-groups#AutomaticFailover","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AGMultipleDHCPListenerSubnets","definition","TRUE","Low","Availability group listener network mode","Reconfigure '@{dns_name}' listener for '@{ag_name}' availability group. Use static IP addresses across multiple subnets","","DHCP network mode is limited to a single subnet that is used for every server instances that hosts a replica in the availability group. To create an availability group across multiple subnets, each subnet requires a static IP address in the listener configuration.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/create-or-configure-an-availability-group-listener-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AGReplicasDisconnected","definition","TRUE","Low","Availability replica connection state","Resolve connection issue on availability replica '@{ag_replica_server}' in availability group '@{ag_name}'","DefaultRuleset, AlwaysOn","An availability group supports a replicated environment for a discrete set of user databases, known as availability databases. Each set of availability databases is hosted by an availability replica. Two types of availability replicas exist: a single primary replica, which hosts the primary databases, and one to eight secondary replicas, each of which hosts a set of secondary databases and serves as potential failover targets for the availability group. The primary replica sends transaction log records of each primary database to every secondary database. This process - known as data synchronization - occurs at the database level. Every secondary replica caches the transaction log records and then applies them to its corresponding secondary database.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/overview-of-always-on-availability-groups-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,, +"AGReplicasRecoveryHealth","definition","TRUE","Low","Availability replica recovery health","Resolve recovery health state on availability replica '@{ag_replica_server}' in availability group '@{ag_name}'","DefaultRuleset, AlwaysOn","An availability group supports a replicated environment for a discrete set of user databases, known as availability databases. Each set of availability databases is hosted by an availability replica. Two types of availability replicas exist: a single primary replica, which hosts the primary databases, and one to eight secondary replicas, each of which hosts a set of secondary databases and serves as potential failover targets for the availability group. The primary replica sends transaction log records of each primary database to every secondary database. This process - known as data synchronization - occurs at the database level. Every secondary replica caches the transaction log records and then applies them to its corresponding secondary database.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/overview-of-always-on-availability-groups-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AGReplicasSynchronized","definition","TRUE","Low","Availablity replica synchronization health","Resolve synchronization issues on availability replica '@{ag_replica_server}' in availability group '@{ag_name}'","DefaultRuleset, AlwaysOn","An availability group supports a replicated environment for a discrete set of user databases, known as availability databases. Each set of availability databases is hosted by an availability replica. Two types of availability replicas exist: a single primary replica, which hosts the primary databases, and one to eight secondary replicas, each of which hosts a set of secondary databases and serves as potential failover targets for the availability group. The primary replica sends transaction log records of each primary database to every secondary database. This process - known as data synchronization - occurs at the database level. Every secondary replica caches the transaction log records and then applies them to its corresponding secondary database.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/overview-of-always-on-availability-groups-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,, "AGTotalNumber","definition","TRUE","Low","Maximum number of Availability Groups","Review the number of Availability Groups (@{ag_id}) currently hosted on the SQL Server instance","DefaultRuleset, AlwaysOn","The actual number of databases and availability groups you can put on a computer (VM or physical) depends on the hardware and workload, but there is no enforced limit. Microsoft has tested up to 10 AGs and 100 DBs per physical machine. Signs of overloaded systems can include, but are not limited to, worker thread exhaustion, slow response times for availability group system views and DMVs, and/or stalled dispatcher system dumps.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/prereqs-restrictions-recommendations-always-on-availability#PrerequisitesForAGs","Server","Windows Linux",,"SqlServer","[11.0,)",,"10", "AllowUpdates","definition","TRUE","Low","Non-default value for 'allow updates' option","Review non-default value @{allow_updates} for the 'allow updates' option as it has no effect and will be removed in a future version","DefaultRuleset, Performance, Configuration","The 'allow updates' option has no effect and will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.","https://docs.microsoft.com/sql/database-engine/configure-windows/allow-updates-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "AutoStartProcs","definition","TRUE","Low","Automated execution of stored procedures is enabled","Disable automated execution of stored procedures: @{sp_name}","DefaultRuleset, Configuration, Security, Performance","Automated execution of stored procedures during the SQL Server startup may delay the availability of the SQL Server instance during the startup procedure. It also introduces the risk of execution of unauthorized code.","https://docs.microsoft.com/sql/relational-databases/stored-procedures/execute-a-stored-procedure#execute-stored-procedures-automatically","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "AutoUpdateStatsAsync","definition","TRUE","Information","Option 'AUTO_UPDATE_STATISTICS_ASYNC' is enabled","Disable 'AUTO_UPDATE_STATISTICS_ASYNC' option","DefaultRuleset, Configuration","The Query Optimizer could choose a suboptimal query plan if statistics are out-of-date when the query compiles. User database has AUTO_UPDATE_STATISTICS_ASYNC enabled on one or more user databases. ","https://docs.microsoft.com/sql/t-sql/statements/alter-database-transact-sql-set-options#auto_update_statistics_async","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, -"AzDataDiskCache","definition","TRUE","High","Azure disk caching for data files","Set caching to 'ReadOnly' for disk @{name} (@{volume_mount_point}) as it is used for storing data files. Current setting: '@{caching}'","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","Uncached IOPS and throughput plus Cached IOPS and throughput will yield the total possible performance available from the virtual machine within the VMs limits.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempdb",, +"AzDataDiskCache","definition","TRUE","High","Azure disk caching for data files","Set caching to 'ReadOnly' for disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) as it is used for storing data files. Current setting: '@{caching}'","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","Uncached IOPS and throughput plus Cached IOPS and throughput will yield the total possible performance available from the virtual machine within the VMs limits.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempdb",, "AzDataDiskStriping","definition","TRUE","Information","Azure data disk striping","Consider using data disk striping to increase I/O bandwidth of volume @{volume_mount_point}","DefaultRuleset, Configuration, Performance","There are throughput and bandwidth limits at the data disk level. Applications that consume resources beyond these limits will be throttled. For more throughput and bandwidth, you can add additional data disks and use disk striping. You can use Storage Spaces inside a virtual machine to combine multiple data disks, creating more storage capacity or performance than is available from a single data disk.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#disk-striping","Server","Windows","AzureVm","SqlServer","[11.0,)",,, "AzDataOnDataDisks","definition","TRUE","Medium","Data files on Azure data disks","Move data files from @{volume_mount_point} to Premium SSD data disk(s)","DefaultRuleset, DBFileConfiguration, DBConfiguration","Azure data disks can be configured for optimal data security and performance. ","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempdb",, "AzDataOnDataDisks","override","TRUE","Low",,,"",,,,,,,,"master model msdb",, "AzDbDefaultLocation","definition","TRUE","Medium","Database default locations","Configure default @{setting_name} file location","DefaultRuleset, Configuration, Performance","Default database file location setting makes new data and transaction log files placed on drives configured for this specific workload.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Server","Windows","AzureVm","SqlServer","[11.0,)",,, "AzDiskColumnCount","definition","TRUE","Medium","Storage spaces disk column count","Use all @{poolDiskCount} physical disks available in your storage pool for virtual disk (@{volume_mount_point}), currently used: @{columnCount} physical disk(s)","DefaultRuleset, DBFileConfiguration, DBConfiguration, Performance","Increasing virtual disk column count improves the disk's performance. The number of disks in the pool is the maximum available number of columns.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Server","Windows","AzureVm","SqlServer","[11.0,)",,, "AzErrorLogLocation","definition","TRUE","Medium","Error log and default trace files on Azure data disk","Move error log and default trace files to data disk","DefaultRuleset, Configuration, Performance","Storing error log and default trace files on data disk improves performance.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Server","Windows","AzureVm","SqlServer","[11.0,)",,, -"AzPremSsdDataFiles","definition","TRUE","High","Use premium SSDs for SQL Server data files","Move data files from @{volume_mount_point} to Premium SSD disk","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","Standard HDDs and SSDs have varying latencies and bandwidth and are only recommended for dev/test workloads. Production workloads should use premium SSDs.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempDb",, +"AzPremSsdDataFiles","definition","TRUE","High","Use premium SSDs for SQL Server data files","Move data files from disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) to Premium SSD disk","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","Standard HDDs and SSDs have varying latencies and bandwidth and are only recommended for dev/test workloads. Production workloads should use premium SSDs.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempDb",, "AzPremSsdDataFiles","override","TRUE","Low",,,"",,,,,,,,"master model msdb",, "AzTempDbFileLocation","definition","TRUE","High","Tempdb files on Azure temp drive","Move tempdb files from @{volume_mount_point} to the local ephemeral SSD (temp disk)","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","Storing tempdb files on a local ephemeral SSD improves the performance of workloads that use temporary objects heavily (e.g. queries handling large recordsets, index rebuilds, row versioning isolation levels, temp tables, and triggers).","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Database","Windows","AzureVm","SqlServer","[11.0,)","tempdb",, -"AzTranLogDiskCache","definition","TRUE","High","Azure disk caching for transaction logs","Set caching to 'None' for disk @{name} (@{volume_mount_point}) as it is used for storing transaction log files. Current setting: '@{caching}'","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","There is no performance benefit to enabling caching for the Transaction log disk, and in fact having either Read-only or Read/Write caching enabled on the log drive can decrease the amount of cache available for reads on the data drive","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempdb",, +"AzTranLogDiskCache","definition","TRUE","High","Azure disk caching for transaction logs","Set caching to 'None' for disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) as it is used for storing transaction log files. Current setting: '@{caching}'","DefaultRuleset, Performance, DBFileConfiguration, DBConfiguration","There is no performance benefit to enabling caching for the Transaction log disk, and in fact having either Read-only or Read/Write caching enabled on the log drive can decrease the amount of cache available for reads on the data drive","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies","Database","Windows","AzureVm","SqlServer","[11.0,)","NOT: tempdb",, "BackupCompression","definition","TRUE","Information","Option 'backup compression default' is disabled","Enable 'backup compression default' option","DefaultRuleset, Configuration, Performance, Backup","The 'backup compression default' option determines whether the server instance creates compressed backups by default. Because a compressed backup is smaller than an uncompressed backup of the same data, compressing a backup typically requires less device I/O and therefore usually increases backup speed significantly.","https://docs.microsoft.com/sql/database-engine/configure-windows/view-or-configure-the-backup-compression-default-server-configuration-option","Server","Windows Linux",,"Standard, Enterprise, ManagedInstance","[11.0,)",,, "BackupTables","definition","TRUE","Information","Too many rows in backup or restore history tables","Reduce number of rows in table '@{table_name}' to less than @{threshold}","DefaultRuleset, Configuration","The upgrade process of a SQL Server instance may appear to hang if the number of rows in the following backup and restore system tables is very high: 'backupfile', 'backupmediafamily', 'backupmediaset', 'backupset', 'restorefile', 'restorefilegroup', 'restorehistory'. This is due to the fact that it would take longer to modify the backup and restore system tables in MSDB database.","https://docs.microsoft.com/sql/relational-databases/system-stored-procedures/sp-delete-backuphistory-transact-sql","Server","Windows Linux",,"SqlServer","[11.0,)",,"10000", "C2AuditMode","definition","TRUE","Information","Non-default value for 'c2 audit mode' option","Review non-default value @{c2_audit_mode} for the 'c2 audit mode' option as it will be removed in a future version","DefaultRuleset, Configuration","When enabled, the 'c2 audit mode' option collects all attempts to access statements and objects. Enabling this option triggers a significant amount of data collection over a short period of time for even moderately active Microsoft SQL Server instances.","https://docs.microsoft.com/sql/database-engine/configure-windows/c2-audit-mode-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "CCCompliance","definition","TRUE","Information","Non-default value for 'common criteria compliance enabled' option","Review non-default value @{common_criteria_compliance_enabled} for the 'common criteria compliance enabled' option","DefaultRuleset, Performance, Configuration","SQL Server is being developed to achieve not only the best performance results but also to be the most secure database system ever released. Microsoft has the commitment to be compliant with the most important standards. The most recent SQL Server Editions are getting these recognitions, including the Common Criteria certification. Part of that commitment is the independent third-party evaluation of our products and in using the Common Criteria (CC, ISO15408) as a proven and accepted process to ensure compliance with Common Evaluation Methodologies.","https://docs.microsoft.com/sql/database-engine/configure-windows/common-criteria-compliance-enabled-server-configuration-option","Server","Windows Linux",,"Enterprise, ManagedInstance","[11.0,)",,, "ClrEnabled","definition","TRUE","Information","Non-default value for 'clr enabled' option","Review non-default value @{clr_enabled} for the 'clr enabled' option","DefaultRuleset, Configuration","This option determines whether user assemblies and CLR functionality or objects can be used on a Microsoft SQL Server instance. Disable this option if you do not plan to use CLR database objects on the SQL Server instance.","https://docs.microsoft.com/sql/relational-databases/clr-integration/clr-integration-enabling","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ColumnstoreLargePageModel","definition","TRUE","Medium","Columnstore indexes with large page memory model","Disable trace flag 834 when using Columnstore indexes","","Interoperability of Columnstore indexes with large page memory model may cause severe performance issues, access violations, insufficient system memory errors, or a non-yielding Scheduler errors.","https://docs.microsoft.com/sql/t-sql/database-console-commands/dbcc-traceon-trace-flags-transact-sql#tf834","Server","Windows Linux",,"SqlServer","[11.0,)",,, "CompareRunConfigured","definition","TRUE","Information","Run and config values are different","Use 'RECONFIGURE' after 'sp_configure' to update run value. Config value is different from run value in: @{unsaved_option}","DefaultRuleset, Performance, Configuration","SQL Server instance configuration settings have two values: a run value which is the currently active value and a config value which is the value that was last configured. Generally, these two values are the same, but if a setting has been changed but the change is not yet applied, confusion can arise for administrators and, in extreme cases, the system can become unstable.","https://docs.microsoft.com/sql/relational-databases/system-catalog-views/sys-configurations-transact-sql","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"CompilationsPerSec","definition","TRUE","Low","High SQL compilations frequency","Investigate the use of stored procedures, database options and server options to reduce the proportion of plan compilations to batch requests per second (@{sql_compilations_sec:0.##} / @{batch_request_sec:0.##})","DefaultRuleset, Performance","SQL Server will try to reuse compiled plans from the plan cache. The reuse of a plan means that a new plan does not need to be optimized and compiled and results in greater efficiency. A high proportion of compilations indicates many ad-hoc queries and will result in inefficiency. Use sp_executesql for dynamic SQL statements. In addition, investigate the possibility of changing prepared SQL and ad-hoc SQL statements to stored procedures. The FORCED PARAMETERIZATION option can be set at the database level. This makes SQL Server become much more aggressive in deciding which queries to auto-parameterize, but can potentially introduce parameter-sensitivity problems (e.g. parameter sniffing).","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-sql-statistics-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.1", "ContainedDbAuthentication","definition","TRUE","Information","Non-default value for 'contained database authentication' option","Review non-default value @{contained_database_authentication} for the 'contained database authentication' option","DefaultRuleset, Configuration, Security","When contained databases are enabled, database users other than members of the 'sysadmin' and 'securityadmin' fixed server roles can grant access to the instance of SQL Server.","https://docs.microsoft.com/sql/database-engine/configure-windows/contained-database-authentication-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"CursorRequestsPerSec","definition","TRUE","Low","High cursor requests frequency","Determine if cursors are the most appropriate means to accomplish the processing or whether a set-based operation, which is generally more efficient, is possible, Cursor Requests/sec (@{cursor_requests_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}) is greater than @{threshold:P0}","DefaultRuleset, Performance","Cursor Requests/sec is the number of cursor requests received by SQL Server. More than 20 cursor requests per 100 Batch Requests/sec on an average may indicate that the applications are designed to use cursors extensively instead of set-based operations. Look at the Cursor Requests/sec counter to get a general overview for how many cursors are being used on the system. Systems that have high CPU utilization because of small fetch sizes typically have hundreds of cursor requests per second. Redesign queries and applications to use set-based operations rather than cursors where possible.","https://techcommunity.microsoft.com/t5/sql-server-blog/increase-your-sql-server-performance-by-replacing-cursors-with/ba-p/383359","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.2", "CursorThreshold","definition","TRUE","Information","Non-default value for 'cursor threshold' option","Review non-default value @{cursor_threshold} for the 'cursor threshold' option","DefaultRuleset, Performance, Configuration","When cursors generate keysets for a result set, the query optimizer estimates how many rows the keyset will contain. If the number is larger than this threshold, the keyset is generated asynchronously. The default value of -1 results in SQL Server generating all keysets asynchronously. If you set the value too low, overall performance may be impacted because small results sets are better built synchronously.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-cursor-threshold-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "DatabaseMailXPs","definition","TRUE","Information","Non-default value for 'Database Mail XPs' option","Review non-default value @{Database_Mail_XPs} for the 'Database Mail XPs' option","DefaultRuleset, Configuration, Security","Configuring the 'Database Mail XPs' option to 1 enables Database Mail on the instance of SQL Server. This configuration is off by default to reduce the attack surface area of SQL Server. Do not enable this functionality unless you intend to use Database Mail.","https://docs.microsoft.com/sql/database-engine/configure-windows/database-mail-xps-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"DbBackupMedia","definition","TRUE","Low","Backup files on a separate physical location","Place backup file @{physical_device_name} on a separate physical location from the database files","DefaultRuleset, Backup, Performance, Configuration, DBConfiguration, DBFileConfiguration","It is recommended that database backups are placed on a separate physical location or device from the database files. When your physical drive that stores your databases malfunctions or crashes, recoverability depends on the ability to access the separate drive or remote device that stored the backups in order to perform a restore. Also, putting the database and backup files on the separate devices optimizes the I/O performance for both the production use of the database and the writing of backups.","https://learn.microsoft.com/sql/relational-databases/backup-restore/back-up-and-restore-of-sql-server-databases#best-practice-recommendations","Database","Windows",,"SqlServer","[11.0,)",,, "DbCompression","definition","TRUE","Information","Uncompressed database tables and indexes","Turn on compression for these @{ObjectType}: @{ObjectName}, total space used by these objects: @{TotalSpaceMB:N2} MB","DefaultRuleset, Configuration, Performance","The compression capability at either the row or page level provides an opportunity to save disk space and improve performance, with the tradeoff of requiring a bit more CPU to compress and decompress the data, but requiring less memory and disk access improving performance in many workloads. The data pages are kept compressed when they are uploaded to memory. This check fires if a relatively large amount of space is on indexes without compression (for example, more than 10GB).","https://docs.microsoft.com/sql/relational-databases/sql-server-index-design-guide","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)","NOT: master model msdb tempdb","1280000", +"DbMirroring","definition","TRUE","Low","Database mirroring","Plan to modify applications that currently use database mirroring as it is deprecated and will be removed in a future version","DefaultRuleset, Configuration, Deprecated","Database mirroring is a solution for increasing the availability of a SQL Server database. Mirroring is implemented on a per-database basis and works only with databases that use the full recovery model. Database mirroring is deprecated and will be removed in a future version of SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. Use Always On availability groups instead.","https://learn.microsoft.com/sql/database-engine/database-mirroring/database-mirroring-sql-server","Server","Windows",,"SqlServer","[11.0,)",,, "DbRecoveryModel","definition","TRUE","Medium","Databases with 'SIMPLE' recovery model","Change recovery model to 'FULL' or 'BULK_LOGGED'","DefaultRuleset, Configuration","A database with the 'SIMPLE' recovery model does not support log backups. As a result, when you need to restore such a database, all the transactions since the last database backup or differential backup will be lost. Review databases that have the 'SIMPLE' recovery model. If the maximum amount of data loss involved is not acceptable, change the recovery model to 'FULL' or 'BULK_LOGGED' and schedule frequent log backups.","https://docs.microsoft.com/sql/relational-databases/backup-restore/recovery-models-sql-server","Database","Windows Linux",,"SqlServer","[11.0,)","NOT: model tempdb msdb master",, -"DbSpaceAvailable","definition","TRUE","Medium","Low free space in data files","Increase space for data files. Currently @{spaceAvailableRel:P0} is available. Threshold is set to @{threshold:P0}. Total size of data files: @{totalMB:N2} MB. Free space: @{freeMB:N2} MB","DefaultRuleset, Configuration, DBFileConfiguration","Average available space in data files is less than the threshold.","https://docs.microsoft.com/sql/relational-databases/databases/database-states","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.25", -"DbStandby","definition","TRUE","Information","STANDBY mode is enabled","Disable STANDBY mode for database","DefaultRuleset, Configuration","A Database in STANDBY mode will be online as READ ONLY, WITH RESTORE LOG allowed. If recovery is not complete, then the availability of the database might be affected. Usually log shipped secondary databases are configured to be in STANDBY mode.","https://docs.microsoft.com/sql/t-sql/statements/restore-statements-arguments-transact-sql#with-options","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"DbSpaceAvailable","definition","TRUE","Medium","Low free space in data files","Increase space for data files. Currently @{spaceAvailableRel:P0} is available. Threshold is set to @{threshold:P0}. Total size of data files: @{totalMB:N2} MB. Free space: @{freeMB:N2} MB","DefaultRuleset, Configuration, DBFileConfiguration","Average available space in data files is less than the threshold.","https://docs.microsoft.com/troubleshoot/sql/admin/considerations-autogrow-autoshrink#why-do-i-have-to-worry-about-disk-space-if-size-settings-are-automatically-controlled","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.25", +"DbStandby","definition","TRUE","Information","STANDBY mode is enabled","Check database availability. A database is in STANDBY mode","DefaultRuleset, Configuration","A database in STANDBY mode will be online as READ ONLY, WITH RESTORE LOG allowed. If recovery is not complete, then the availability of the database might be affected. Usually log shipped secondary databases are configured to be in STANDBY mode.","https://docs.microsoft.com/sql/t-sql/statements/restore-statements-arguments-transact-sql#with-options","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "DbState","definition","TRUE","Low","Database with unavailable state","Check '@{DbName}' database availability. Current database state is: @{DbStateDesc}","DefaultRuleset, Configuration","Database unavailability may affect expected application behavior due to the impossibility of establishing user connections. The issue occurs when a database is in any of the following states: 'RECOVERY_PENDING', 'RECOVERING', 'SUSPECT', or 'RESTORING'.","https://docs.microsoft.com/sql/relational-databases/databases/database-states","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"DeadlockFrequency","definition","TRUE","Low","High deadlock frequency","Investigate a high frequency of deadlocked transactions (@{number_of_deadlocks_sec:0.##})","DefaultRuleset, Performance","One or more SQL Server instances report a high frequency of deadlocked transactions. This can result in blocking, reduced concurrency, and degraded performance. Get more details on the processes that are causing deadlock between each other. To view deadlock information, the Database Engine provides monitoring tools in the form of Extended Event Sessions with the Deadlock Graph event or the trace flags 1204 or 1222 which writes more detailed information to the SQL Server Error log. Once you have identified the problematic queries you need to optimize the code, indexes, order of operations and isolation level used and required by the process.","https://learn.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide?#deadlocks","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "DisallowResultsTriggers","definition","TRUE","Information","Option 'disallow results from triggers' is disabled","Enable 'disallow results from triggers' option as the ability to return result sets from triggers will be removed in a future version","DefaultRuleset, Configuration","Use the 'disallow results from triggers' option to control whether triggers return result sets. Triggers that return result sets may cause unexpected behavior in applications that are not designed to work with them.","https://docs.microsoft.com/sql/database-engine/configure-windows/disallow-results-from-triggers-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"DomainController","definition","TRUE","Medium","SQL Server on a domain controller","SQL Server is installed on a domain controller. Consider migrating SQL Server to a dedicated machine","DefaultRuleset, Configuration, Security","For security reasons, it is strongly not recommend installing SQL Server on a domain controller.","https://learn.microsoft.com/sql/sql-server/install/hardware-and-software-requirements-for-installing-sql-server#DC_support","Server","Windows",,"SqlServer","[11.0,)",,, "EKMProvider","definition","TRUE","Information","Non-default value for 'EKM provider enabled' option","Review non-default value @{EKM_provider_enabled} for the 'EKM provider enabled' option","DefaultRuleset, Configuration","The 'EKM provider enabled' option controls Extensible Key Management device support in SQL Server. SQL Server provides data encryption capabilities together with Extensible Key Management (EKM), using the Microsoft Cryptographic API (MSCAPI) provider for encryption and key generation. Encryption keys for data and key encryption are created in transient key containers, and they must be exported from a provider before they are stored in the database. This approach enables key management that includes an encryption key hierarchy and key backup, to be handled by SQL Server.","https://docs.microsoft.com/sql/database-engine/configure-windows/ekm-provider-enabled-server-configuration-option","Server","Windows Linux",,"Standard, Enterprise, ManagedInstance","[11.0,)",,, "EKMProvider","override","False","Low",,,"",,,,,,"Standard","[11.0, 15.0)",,, +"ErrorLog109","definition","TRUE","Medium","Database engine error 109","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","There are more columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in the INSERT statement.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog211","definition","TRUE","High","Database engine error 211","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Possible schema corruption.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog232","definition","TRUE","Information","Database engine error 232","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Arithmetic overflow error.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog566","definition","TRUE","Medium","Database engine error 566","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An error occurred while writing an audit trace.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog602","definition","TRUE","Information","Database engine error 602","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not find an entry for table or index. This error can occur if a stored procedure references a dropped table, or metadata is corrupted.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog603","definition","TRUE","Information","Database engine error 603","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not find an entry for table or index. This error can occur if a stored procedure references a dropped table, or metadata is corrupted.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog605","definition","TRUE","Medium","Database engine error 605","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Attempt to fetch a logical page failed. This error generally signifies page or allocation corruption, and often is caused by hardware or disk device driver failure.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-605-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog608","definition","TRUE","Medium","Database engine error 608","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","No catalog entry found for partition. The metadata is inconsistent.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog701","definition","TRUE","Information","Database engine error 701","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","There is insufficient system memory in resource pool to run this query. Insufficient memory can be caused by a number of factors that include operating system settings, physical memory availability, other components use memory inside SQL Server, or memory limits on the current workload.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-701-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog802","definition","TRUE","Medium","Database engine error 802","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","There is insufficient memory available in the buffer pool. This is caused when the buffer pool is full and the buffer pool cannot grow any larger.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-802-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog823","definition","TRUE","Medium","Database engine error 823","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The operating system returned error to SQL Server. This error usually indicates that there is a problem with underlying storage system or the hardware or a driver that is in the path of the I/O request.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-823-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog824","definition","TRUE","Medium","Database engine error 824","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server detected a logical consistency-based I/O error. This error usually indicates that there is a problem with underlying storage system or the hardware or a driver that is in the path of the I/O request.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-824-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog825","definition","TRUE","Medium","Database engine error 825","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A read of a file succeeded after failing one or more times. This error indicates that the read operation had to be reissued at least one time, and indicates a major problem with the disk hardware.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-825-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog829","definition","TRUE","High","Database engine error 829","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A page is marked as RestorePending, which may indicate disk corruption. To recover from this state, perform a restore.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog832","definition","TRUE","Medium","Database engine error 832","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A page that should have been constant has changed. This usually indicates a memory failure or other hardware or operating system corruption. An external factor has caused a database page to be modified outside the normal SQL Server engine code used to change database pages.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-832-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog833","definition","TRUE","Information","Database engine error 833","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server has encountered occurrences of I/O requests taking a long time to complete. This error indicates a problem with the I/O subsystem. This problem can be caused by operating system performance issues, hardware errors, firmware errors, device driver problems, or filter driver intervention in the I/O process or storage path of database files.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-833-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog844","definition","TRUE","Information","Database engine error 844","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting for buffer latch. A process is waiting to acquire a latch. This can occur if an I/O operation taking too long to complete.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-844-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog845","definition","TRUE","Information","Database engine error 845","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting for buffer latch. A process was waiting to acquire a latch, but the process waited until the time limit expired and failed to acquire one. This can occur if an I/O operation takes too long to complete.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-845-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog846","definition","TRUE","Information","Database engine error 846","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting for buffer latch. Not continuing to wait. A computer might stop responding, or a timeout or some other disruption of regular operations might occur at the same time that SQL Server writes buffer latch errors to the SQL Server error log.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-846-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog847","definition","TRUE","Information","Database engine error 847","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting for buffer latch. Continuing to wait. A computer might stop responding, or a timeout or some other disruption of regular operations might occur at the same time that SQL Server writes buffer latch errors to the SQL Server error log.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-847-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog905","definition","TRUE","Information","Database engine error 905","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database cannot be started because it contains one or more partitioned tables or indexes. This edition of SQL Server cannot use table and index partitioning.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-905-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog909","definition","TRUE","Information","Database engine error 909","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database cannot be started because it contains one or more objects enabled with data compression or vardecimal storage format. This edition of SQL Server cannot use data compression and vardecimal storage format.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog933","definition","TRUE","Information","Database engine error 933","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database cannot be started because some of the database functionality is not available in this edition of SQL Server.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog934","definition","TRUE","Information","Database engine error 934","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server cannot load a database because Change Data Capture is enabled. This edition of SQL Server does not support Change Data Capture.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog945","definition","TRUE","Medium","Database engine error 945","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database cannot be opened due to inaccessible files or insufficient memory or disk space.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-945-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog1101","definition","TRUE","Medium","Database engine error 1101","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not allocate a new page because of insufficient disk space.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1101-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog1105","definition","TRUE","Medium","Database engine error 1105","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not allocate space for an object because a filegroup is full.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1105-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog1205","definition","TRUE","Information","Database engine error 1205","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Transaction was deadlocked on a resources with another process and has been chosen as the deadlock victim. This error indicates that resources are accessed in conflicting order on separate transactions, causing a deadlock.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1205-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog1450","definition","TRUE","Medium","Database engine error 1450","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The ALTER DATABASE command failed because the worker thread cannot be created.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog2570","definition","TRUE","Medium","Database engine error 2570","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A column value is outside the range of possible values for the column data type.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-2570-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3041","definition","TRUE","Medium","Database engine error 3041","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","BACKUP failed to complete a command.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3043","definition","TRUE","Medium","Database engine error 3043","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","BACKUP detected an error on page.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3197","definition","TRUE","Information","Database engine error 3197","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","I/O is frozen on a database.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3260","definition","TRUE","Information","Database engine error 3260","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An internal buffer has become full. The server is out of memory.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3260-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3266","definition","TRUE","Information","Database engine error 3266","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A backup data is incorrectly formatted. Backup sets on the media might be damaged and unusable.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3271","definition","TRUE","Information","Database engine error 3271","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A nonrecoverable I/O error occurred. This is a general error that occurs when the operating system raises an error while performing I/O during a backup or restore operation.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3271-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3313","definition","TRUE","Medium","Database engine error 3313","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","During redoing of a logged operation, an error occurred.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3313-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3314","definition","TRUE","Medium","Database engine error 3314","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","During undoing of a logged operation, an error occurred.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3314-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3316","definition","TRUE","Information","Database engine error 3316","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","During undo of a logged operation, an error occurred. The row was not found.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3409","definition","TRUE","Medium","Database engine error 3409","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Performance counter shared memory setup failed.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3414","definition","TRUE","Medium","Database engine error 3414","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An error occurred during recovery, preventing a database from restarting.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3414-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3417","definition","TRUE","Medium","Database engine error 3417","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Cannot recover the master database. SQL Server is unable to run.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3417-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3420","definition","TRUE","Information","Database engine error 3420","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database snapshot has failed an IO operation and is marked suspect.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3431","definition","TRUE","Medium","Database engine error 3431","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not recover a database because of unresolved transaction outcomes.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3431-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3437","definition","TRUE","Medium","Database engine error 3437","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An error occurred while recovering a database. Unable to connect to Distributed Transaction Coordinator to check the completion status of a transaction.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3437-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3452","definition","TRUE","Information","Database engine error 3452","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Recovery of a database detected possible identity value inconsistency in a table.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3452-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3456","definition","TRUE","Medium","Database engine error 3456","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not redo log record.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3456-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3619","definition","TRUE","Medium","Database engine error 3619","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not write a checkpoint record because the log is out of space. The transaction log is out of disk space.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3619-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog3859","definition","TRUE","Medium","Database engine error 3859","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The system catalog was updated directly. This error indicates a user initiated changes to system tables. Manually updating system tables is not supported.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3859-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog5105","definition","TRUE","Medium","Database engine error 5105","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A file activation error occurred. The physical file name may be incorrect.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog5180","definition","TRUE","Medium","Database engine error 5180","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not open File Control Bank for invalid file. A query or operation may fail when an invalid file ID is referenced.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-5180-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog5243","definition","TRUE","Information","Database engine error 5243","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An inconsistency was detected during an internal operation. SQL Server detected a structural inconsistency in an in-memory storage engine structure.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-5243-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog7105","definition","TRUE","Information","Database engine error 7105","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A large object data referenced by a database page row cannot be accessed. This is usually caused by transactions that can read uncommitted data on a data page.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-7105-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog7359","definition","TRUE","Information","Database engine error 7359","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The OLE DB provider for a linked server reported a change in schema version between compile time and run time.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8621","definition","TRUE","Medium","Database engine error 8621","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The query processor ran out of stack space during query optimization. The size of the expanded query is the most likely cause of the error.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8621-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8628","definition","TRUE","Medium","Database engine error 8628","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting to optimize the query.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8642","definition","TRUE","Medium","Database engine error 8642","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The query processor could not start the necessary thread resources for parallel query execution.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8642-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8645","definition","TRUE","Information","Database engine error 8645","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A timeout occurred while waiting for memory resources to execute the query.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8645-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8909","definition","TRUE","Medium","Database engine error 8909","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A page contains an incorrect page ID in its page header.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog8966","definition","TRUE","Information","Database engine error 8966","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Unable to read and latch page.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8966-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9002","definition","TRUE","Medium","Database engine error 9002","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A database transaction log is full.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9002-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9004","definition","TRUE","High","Database engine error 9004","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An error was encountered while processing the log during rollback, recovery, or replication. This could indicate an error detected by the operating system or an internal consistency error detected by SQL Server.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9004-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9642","definition","TRUE","Information","Database engine error 9642","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An error occurred in a Service Broker/Database Mirroring transport connection endpoint.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9691","definition","TRUE","Medium","Database engine error 9691","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An endpoint has stopped listening for connections.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9692","definition","TRUE","Information","Database engine error 9692","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An endpoint cannot listen on a port because it is in use by another process.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9692-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog9693","definition","TRUE","Information","Database engine error 9693","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An endpoint cannot listen for connections due to an error.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17065","definition","TRUE","Medium","Database engine error 17065","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17065-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17066","definition","TRUE","Medium","Database engine error 17066","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17066-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17067","definition","TRUE","Medium","Database engine error 17067","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17067-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17194","definition","TRUE","Medium","Database engine error 17194","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","This error indicates that the client has closed the connection. This error could occur because the connection timeout has expired.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17194-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17204","definition","TRUE","Information","Database engine error 17204","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Could not open a file. SQL Server was unable to open the file because of the operating system error.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17204-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17207","definition","TRUE","Information","Database engine error 17207","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An operating system error occurred while creating or opening a file. SQL Server was unable to open the file because of the operating system error.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17207-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17659","definition","TRUE","High","Database engine error 17659","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A system table has been updated directly and cache coherence may not have been maintained. This error indicates a user initiated changes to system tables. Manually updating system tables is not supported.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17659-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17806","definition","TRUE","Medium","Database engine error 17806","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Security Support Provider Interface handshake failed while establishing a connection with integrated security.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17832","definition","TRUE","Information","Database engine error 17832","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The login packet used to open the connection is structurally invalid. This error could occur because the packet was created improperly or because the packet was damaged during transmission.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17832-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17884","definition","TRUE","Medium","Database engine error 17884","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","New queries assigned to process have not been picked up by a worker thread.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17884-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17887","definition","TRUE","Medium","Database engine error 17887","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","An IO Completion Listener appears to be non-yielding. This error indicates that there is a possible problem with the I/O Completion Port Listener when executing the I/O Completion routine for a network read/write event.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17887-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17888","definition","TRUE","Medium","Database engine error 17888","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","All schedulers on a node appear deadlocked due to a large number of waiting worker threads.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog17890","definition","TRUE","Medium","Database engine error 17890","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A significant part of SQL Server process memory has been paged out. This may result in a performance degradation.","https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17890-database-engine-error","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog18056","definition","TRUE","Information","Database engine error 18056","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The client was unable to reuse a session, which had been reset for connection pooling. This error may have been caused by an earlier operation failing.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog18204","definition","TRUE","High","Database engine error 18204","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A backup device failed because of the operating system error.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog18272","definition","TRUE","Information","Database engine error 18272","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","During restore restart, an I/O error occurred on a checkpoint file.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog19034","definition","TRUE","Medium","Database engine error 19034","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Cannot start C2 audit trace.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog26023","definition","TRUE","Medium","Database engine error 26023","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server TCP provider failed to listen on a port. TCP port is already in use.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog26024","definition","TRUE","Medium","Database engine error 26024","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server TCP provider failed to listen on a port.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog26037","definition","TRUE","Medium","Database engine error 26037","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server Network Interface library could not register the Service Principal Name (SPN) for SQL Server service. Failure to register an SPN may cause integrated authentication to fall back to NTLM instead of Kerberos.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog26038","definition","TRUE","Medium","Database engine error 26038","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","SQL Server Network Interface library could not register the Service Principal Name (SPN) for SQL Server service. This SPN should be deregistered manually to avoid client authentication errors.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog28034","definition","TRUE","Information","Database engine error 28034","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Connection handshake failed. A login does not have CONNECT permission on the endpoint.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog28036","definition","TRUE","Medium","Database engine error 28036","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Connection handshake failed. The certificate used by the endpoint was not found.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog28047","definition","TRUE","Information","Database engine error 28047","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A login attempt failed with error.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog28048","definition","TRUE","Information","Database engine error 28048","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A login attempt by an user failed with error.","https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog35201","definition","TRUE","Information","Database engine error 35201","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A connection timeout has occurred while attempting to establish a connection to an availability replica. Either a networking or firewall issue exists, or the endpoint address provided for the replica is not the database mirroring endpoint.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog35204","definition","TRUE","Information","Database engine error 35204","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The connection between server instances has been disabled because the database mirroring endpoint was either disabled or stopped.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog35206","definition","TRUE","Information","Database engine error 35206","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A connection timeout has occurred on a previously established connection to an availability replica. Either a networking or a firewall issue exists or the availability replica has transitioned to the resolving role.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog35207","definition","TRUE","Information","Database engine error 35207","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","Connection attempt on an availability group failed because of error.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog35217","definition","TRUE","Medium","Database engine error 35217","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The thread pool for AlwaysOn Availability Groups was unable to start a new worker thread because there are not enough available worker threads.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog41142","definition","TRUE","Medium","Database engine error 41142","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","The availability replica for an availability group cannot become the primary replica. One or more databases are not synchronized or have not joined the availability group.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLog41144","definition","TRUE","Medium","Database engine error 41144","Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.","","A local availability replica is in a failed state. The replica failed to read or update the persisted configuration data.","https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ErrorLogAge","definition","TRUE","Low","Error log retention settings","Revise error log retention settings. Error log contains less than @{threshold} days of history","DefaultRuleset, Configuration","The SQL Server error log contains lots of information that is generated by the SQL Server. The error log file is initialized every time that the instance of SQL Server is started. Specify the maximum number of archived error log files created before they are recycled. The default is 6, not including the current one.","https://learn.microsoft.com/troubleshoot/sql/admin/manage-error-log","Server","Windows Linux",,"SqlServer","[11.0,)",,"14", "FileMaxSize","definition","TRUE","Information","Setting 'Autogrow' for data files","Check 'autogrow' setting. Currently maximum size of @{maxsize_in_mb} MBs is set for @{type_desc} file @{fileName} in database @{databaseName}","DefaultRuleset, Performance, DBFileConfiguration","This check verifies the 'autogrow' settings of data files for all system and user databases. In SQL Server, a log file specified with unlimited growth has a maximum size of 2 TB, and a data file has a maximum size of 16 TB. There is no maximum size when this option is specified for a FILESTREAM container. It continues to grow until the disk is full. If there is no space available, performance issues may occur and the database may become unavailable.","https://docs.microsoft.com/sql/t-sql/statements/alter-database-transact-sql-file-and-filegroup-options","Server","Windows Linux",,"SqlServer","[11.0,)",,, "FilestreamAccessLevel","definition","TRUE","Information","Non-default value for 'filestream access level' option","Review non-default value @{filestream_access_level} for the 'filestream access level' option","DefaultRuleset, Configuration","The 'filestream access level' option controls the FILESTREAM access level for the instance of SQL Server. By default, this option is disabled, but should be enabled to allow FileStream access or to take advantage of the 'FileTable' feature.","https://docs.microsoft.com/sql/database-engine/configure-windows/filestream-access-level-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, -"FillFactor","definition","TRUE","Information","Non-default value for 'fill factor' option","Review non-default value @{fill_factor} for the 'fill factor' option","DefaultRuleset, Performance, Configuration","The 'fill factor' option controls the default fill factor that is used when a new index is created or rebuilt. The default value is 0, which means that the leaf level of the index will be filled with the highest possible number of rows. This option is an advanced option and should be changed only by an experienced database administrator or certified SQL Server professional.","https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/configure-the-fill-factor-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"FillFactor","definition","TRUE","Information","Non-default value for 'fill factor' option","Review non-default value @{fill_factor} for the 'fill factor' option. A low, nonzero 'fill factor' option value can decrease database read performance","DefaultRuleset, Performance, Configuration","The 'fill factor' option controls the default fill factor that is used when a new index is created or rebuilt. The default value is 0, which means that the leaf level of the index will be filled with the highest possible number of rows.","https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/configure-the-fill-factor-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"80", +"FreeSpaceScansPerSec","definition","TRUE","Low","High free space scans rate","Add clustered indexes to heaps and reduce FreeSpace Scans/sec (@{freespace_scans_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}), which is greater than @{threshold:P0}","DefaultRuleset, Performance","Inserts into heaps require SQL Server to perform free space scans to identify pages with free space to insert rows. An insert into a heap often spends time searching for a location to insert the new row. On the other hand the insert into a clustered table does not have to spend any time searching for space. In most cases it is best to start with a clustered index on every table. There are occasional instances where this is not optimal, but it is extremely rare that the existence of a clustered index hurts performance and it usually helps. Test your workload to ensure that adding a clustered index has no detrimental effects.","https://learn.microsoft.com/sql/relational-databases/indexes/heaps-tables-without-clustered-indexes?#when-not-to-use-a-heap","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.1", "FtCrawlBandwidthMax","definition","TRUE","Low","Non-default value for 'ft crawl bandwidth (max)' option","Review non-default value @{ft_crawl_bandwidth_max} for the 'ft crawl bandwidth (max)' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'ft crawl bandwidth (max)' option determines the maximum number of buffers that will be maintained by the full-text memory manager in a small buffer pool. A high value will allocate more memory to the indexing process, therefore reducing the available memory for other SQL Server processes.","https://docs.microsoft.com/sql/database-engine/configure-windows/ft-crawl-bandwidth-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "FtCrawlBandwidthMin","definition","TRUE","Low","Non-default value for 'ft crawl bandwidth (min)' option","Review non-default value @{ft_crawl_bandwidth_min} for the 'ft crawl bandwidth (min)' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'ft crawl bandwidth (min)' option determines the minimum number of buffers that must be maintained by the full-text memory manager in a small buffer pool. If the SQL Server memory manager requests memory, this minimum number of buffers will generally be maintained.","https://docs.microsoft.com/sql/database-engine/configure-windows/ft-crawl-bandwidth-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "FtNotifyBandwidthMax","definition","TRUE","Low","Non-default value for 'ft notify bandwidth (max)' option","Review non-default value @{ft_notify_bandwidth_max} for the 'ft notify bandwidth (max)' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'ft notify bandwidth (max)' option determines the maximum number of buffers that will be maintained by the full-text memory manager in a large buffer pool. A high value will allocate more memory to the indexing process, therefore reducing the available memory for other SQL Server processes.","https://docs.microsoft.com/sql/database-engine/configure-windows/ft-notify-bandwidth-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "FtNotifyBandwidthMin","definition","TRUE","Low","Non-default value for 'ft notify bandwidth (min)' option","Review non-default value @{ft_notify_bandwidth_min} for the 'ft notify bandwidth (min)' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'ft notify bandwidth (min)' option determines the minimum number of buffers that must be maintained by the full-text memory manager in a large buffer pool. If the SQL Server memory manager requests memory, this minimum number of buffers will generally be maintained.","https://docs.microsoft.com/sql/database-engine/configure-windows/ft-notify-bandwidth-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"FullScansVsIndexSearches","definition","TRUE","Low","Full scans vs index searches","Reduce the number of Full Scans (@{full_scans_sec:0.##}) versus Index Searches (@{index_searches_sec:0.##})","DefaultRuleset, Performance","Index searches are preferable to index and table scans. For OLTP applications, optimize for more index searches and less scans. An ideal ratio on a typical system would be approximately 1 full scan for every 1000 index searches. Index searches are preferable to full scans because full scans cause excessive disk I/O and consume more CPU resources. Execution plans or extended events can be used to identify which Transact-SQL statements perform scans. Review table and index strategy, and ensure index and statistics maintenance plans are in place.","https://learn.microsoft.com/sql/relational-databases/sql-server-index-design-guide?#General_Design","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"1000", "FullTextDefaultLang","definition","TRUE","Low","Not supported value for 'default full-text language' option","Set 'default full-text language' option to a supported value","DefaultRuleset, Configuration","The value of the 'default full-text language' option is used in a full-text index when no language is specified. If the default full-text language is not supported or the linguistic analysis package is not available, CREATE FULLTEXT INDEX and ALTER FULLTEXT INDEX statements will fail.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-default-full-text-language-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "FullTextNoiseWords","definition","TRUE","Information","Non-default value for 'transform noise words' option","Review non-default value @{transform_noise_words} for the 'transform noise words' option","DefaultRuleset, Configuration","If a query using a full-text search predicate contains a noise word (for example, is, the, and) and this configuration setting has been disabled, a warning will be issued and no rows from the query will be returned. The default setting for this option is 0, which indicates that it is off. Enabling this configuration by changing the default to 1 will force noise words to be replaced with an asterisk (*) in the query instead.","https://docs.microsoft.com/sql/database-engine/configure-windows/transform-noise-words-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "FullTextPHTimeout","definition","TRUE","Information","Non-default value for 'PH timeout' option","Review non-default value @{PH_timeout} for the 'PH timeout' option","DefaultRuleset, Configuration","The 'PH timeout' option controls the number of seconds that the full-text protocol handler will wait to connect to a database before reaching the timeout threshold. You can increase the 'PH timeout' value when connection attempts are timing out due to temporary network issues.","https://docs.microsoft.com/sql/database-engine/configure-windows/ph-timeout-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "InDoubtXactResolution","definition","TRUE","Information","Non-default value for 'in-doubt xact resolution' option","Review non-default value @{in_doubt_xact_resolution} for the 'in-doubt xact resolution' option","DefaultRuleset, Configuration","The 'in-doubt xact resolution' option controls the default outcome of unresolved Microsoft Distributed Transaction Coordinator (MS DTC) transactions. The default value of 0 means that recovery will fail if MS DTC cannot resolve the in-doubt transactions. Before changing this default, you should consider the effect of your application distributed transactions and make sure that no data integrity issues will occur based on partially committed or aborted activity.","https://docs.microsoft.com/sql/database-engine/configure-windows/in-doubt-xact-resolution-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "InstantFileInitialization","definition","TRUE","High","Instant file initialization (IFI) is disabled","Enable instant file initialization","DefaultRuleset, DBConfiguration, Performance","Instant file initialization (IFI) allows for faster execution of the previously mentioned file operations, since it reclaims used disk space without filling that space with zeros. Instead, disk content is overwritten as new data is written to the files.","https://docs.microsoft.com/en-us/sql/relational-databases/databases/database-instant-file-initialization","Server","Windows",,"SqlServer","[11.0.7001,12.0) [12.0.6024,13.0) [13.0.4001,)",,, "JdbcModuleVersion","definition","TRUE","Medium","JDBC Driver for SQL Server version is not supported","Update JDBC Driver for SQL Server. Current product version @{file_version} of JDBC Driver for SQL Server is out of support","DefaultRuleset, Performance, Security","The JDBC Driver for SQL Server is a Type 4 Java Database Connectivity (JDBC) 4.2 compliant driver that provides robust data access to SQL Server, Azure SQL Database, and Azure SQL Managed Instance. Java connectivity support is continually improving. It is highly recommend to use the latest version of JDBC driver for SQL Server.","https://docs.microsoft.com/sql/connect/jdbc/understanding-xa-transactions","Server","Windows Linux",,"SqlServer","[11.0,)",,, +"LatchWaitTimePerSec","definition","TRUE","Low","High latch wait time","Investigate and resolve the cause of high average Latch Wait Times (@{total_latch_wait_time_ms:0.##} ms for @{latch_waits_sec:0.##} per second)","DefaultRuleset, Performance","The storage engine must ensure that no other task modifies the contents of a memory structure (like a buffer page) while it is being modified by the current task. It does this by acquiring a latch, updating the row in memory (or any other structure protected by a latch), and then releasing the latch. A latch wait indicates the number of times that a latch could not be granted immediately and the task needed to wait.","https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"10", +"LazyWritesPerSec","definition","TRUE","Low","Excessive Lazy Writes","Find and troubleshoot the cause of excessive Lazy writes per second (@{lazy_writes:0.##})","DefaultRuleset, Performance","This counter tracks how many times a second that the Lazy Writer process is moving dirty pages from the buffer to disk in order to free up buffer space. Typically, this should not be more than 20 per second. Ideally, it should be close to zero. This issue usually indicates memory pressure. Even if you can add physical memory to the server to mitigate this issue in the short-term, it is better to find the root cause, commonly inefficient queries, and troubleshoot those. Improving the indexing design, reducing cursor usage, and avoiding scans can significantly improve the value for this counter.","https://learn.microsoft.com/sql/relational-databases/writing-pages","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"20", "LockedPagesInMemory","definition","TRUE","High","Lock pages in memory","Enable the 'Lock pages in memory' option","DefaultRuleset, Performance, Memory","This Windows policy determines which accounts can use a process to keep data in physical memory, preventing the system from paging the data to virtual memory on disk.","https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-checklist","Server","Windows","AzureVm","SqlServer","[11.0,)",,, "LockedPagesInMemory","override","TRUE","Low",,,"",,,,,,,"[11.0.7001, 12.0) [12.0.6024, 13.0) [13.0.4001,)",,, +"LockRequestsPerSec","definition","TRUE","Low","Lock requests per batch","Review the design of high-read queries and attempt to reduce the number of reads (@{lock_requests_sec:0.##} lock requests for @{batch_request_sec:0.##} batch requests)","DefaultRuleset, Performance","Lock Requests/sec reports the number of requests for a type of lock per second. A Lock Requests/sec greater than 500 when compared to Batch Request/sec indicates that batches are acquiring a large number of locks. This suggests inefficient queries. The risk is that blocking may occur. Review high-read queries. In addition, try to reduce the number of reads by tuning your application, the queries executed by the application and the indexing strategy. You can reduce the locks by changing the transaction isolation level, where appropriate.","https://learn.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide?#Lock_Engine","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"LockWaitTime","definition","TRUE","Low","Excessive Lock Waits","Investigate the cause of excessive Lock Waits (@{lock_wait_time_ms:0.##} ms.) and resolve lock contention","DefaultRuleset, Performance","Excessive locking reduces overall throughput and increases the latency observed by users. Investigate the cause of lock contention and reduce this as much as possible to resolve lock wait issues. The following methods can be used to reduce lock contention and increase overall throughput: review index straegy, leverage Read Committed Snapshot and Snapshot Isolation whenever possible, avoid situations in which many processes are attempting to perform updates or inserts on the same data page, avoid transactions that include user interaction, keep transactions that modify data as short as possible, keep transactions in one batch, avoid pessimistic locking hints such as holdlock whenever possible, and reduce the fill factor when creating an index to help diminish the chance of random updates requiring the same page.","http://support.microsoft.com/kb/75722","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", "MaxFTCrawlRange","definition","TRUE","Information","Non-default value for 'max full-text crawl range' option","Review non-default value @{max_full_text_crawl_range} for the 'max full-text crawl range' option","DefaultRuleset, Configuration","The 'max full-text crawl range' option sets the number of partitions that SQL Server will use during a full-text index crawl. The default option is 4. However, you can increase this value if you want to optimize the crawl performance and you have sufficient CPU capacity.","https://docs.microsoft.com/sql/database-engine/configure-windows/max-full-text-crawl-range-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "MaxTextReplSize","definition","TRUE","Information","Non-default value for 'max text repl size' option","Review non-default value @{max_text_repl_size} for the 'max text repl size' option","DefaultRuleset, Configuration","The 'max text repl size' option sets the maximum bytes of varchar(max), nvarchar(max), varbinary(max), xml, image, text, and ntext data that can be replicated in a single INSERT, UPDATE, WRITETEXT, or UPDATETEXT operation. If your data modifications exceed this value on replicated columns, you must increase it.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-max-text-repl-size-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "MediaRetention","definition","TRUE","Information","Non-default value for 'media retention' option","Review non-default value @{media_retention} for the 'media retention' option","DefaultRuleset, Configuration, Backup","The 'media retention' option sets the default length of time to retain a backup set for the Microsoft SQL Server instance. This default length of time protects the set from being overwritten until the specified number of days has elapsed. The default for this configuration is 0 days. However, you can modify it, based on your own corporate policies.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-media-retention-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "MemOptDBResPool","definition","TRUE","Low","In-Memory OLTP database without separate resource pool","Bind In-Memory OLTP database to separate resource pool","Memory, Performance, DefaultRuleset","A databases with memory-optimized tables should be bound to a separate resource pool.","https://docs.microsoft.com/sql/relational-databases/in-memory-oltp/bind-a-database-with-memory-optimized-tables-to-a-resource-pool#bkmk_DefineBinding","Database",,,"SqlServer","[12.0,)",,, +"MemoryGrantsPending","definition","TRUE","Low","Memory grants pending","Tune queries to reduce Memory Grants Pending (@{memory_grants_pending})","DefaultRuleset, Performance","Memory Grants Pending records the number of connections that are waiting for memory before they can begin processing a memory intensive query such as a sort or hash operation. Connections that wait in this state for a long enough time will eventually get an 8645 error (A time out occurred while waiting for memory resources to execute the query. Rerun the query). If this counter remains above zero for a significant period of time, you will need to determine which queries are doing sorts or hashes and will then need to tune them to see if they can utilize a more efficient plan.","https://techcommunity.microsoft.com/t5/sql-server-blog/understanding-sql-server-memory-grant/ba-p/383595","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"MinServerMemory","definition","TRUE","Information","Non-default value for 'min server memory (MB)' option","Review non-default value @{min_server_memory} for the 'min server memory (MB)' option","DefaultRuleset, Configuration","Use the 'min server memory (MB)' option to guarantee a minimum amount of memory available to the SQL Server Memory Manager. The default value for this option is 0. Leave this option at the default value if the SQL Server instance is on a dedicated computer or node that has no other applications or SQL Server instances running concurrently with it.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "MoreIndexesThanCols","definition","TRUE","Information","Tables with more indexes than columns","Consider removing potentially unnecessary indexes on table @{SchemaName}.@{TableName} that has more indexes than columns","DefaultRuleset, Performance, Indexes","One or more database tables have been identified as having more indexes than columns. During inserts, updates and deletes, every index on a table has to be evaluated and, potentially, updated. If too many indexes exist, SQL Server will spend unnecessary resources maintaining indexes that may not be used. This can significantly affect the amount of disk I/O generated and, subsequently, performance.","https://docs.microsoft.com/sql/relational-databases/sql-server-index-design-guide","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)","NOT: master model msdb tempdb",, -"OneDbPerPool","definition","TRUE","Low","One database per resource pool","Check whether only one database is bound to resource pool @{pool_name}","Memory, Performance, DefaultRuleset","Only one database should be bound to a resource pool.","https://docs.microsoft.com/sql/relational-databases/resource-governor/resource-governor-resource-pool","Database",,,"SqlServer","[12.0,)",,, +"NestedTriggers","definition","TRUE","Information","Non-default value for 'nested triggers' option","Review non-default value @{nested_triggers} for the 'nested triggers' option","DefaultRuleset, Configuration","The 'nested triggers' option controls whether an AFTER trigger can cascade. When set to 0, AFTER triggers cannot cascade. The default value for this option is 1.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-nested-triggers-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"OForwardedRecordsPerSec","definition","TRUE","Low","High forwarded records rate","Evaluate index design to reduce Forwarded Records/sec (@{forwarded_records_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}), which is greater than @{threshold:P0}","DefaultRuleset, Performance","Forwarded records occur when a data record in a heap increases in size and the record's current page does not have the space to store the size increase. The record is moved to a new location, becoming a forwarded record, and the forwarding record is left in the original location to point to the real location of the record. The forwarded record points back to the forwarding record in case its location ever needs to change again. If the table experiences several forward records may indicate the table is fragmented and scanning through the table is very inefficient. Review the table index strategy. Forwarded records can be avoided by:Evaluating creating clustered indexes on heaps. Using default values so that an update does not result in a longer row that is the root cause of the forwarded records. Using a fixed size data type such as CHAR instead of VARCHAR. ALTER TABLE … REBUILD to remove heap fragmentation.","https://techcommunity.microsoft.com/t5/sql-server-blog/knowing-about-forwarded-records-can-help-diagnose-hard-to-find/ba-p/383189","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.1", +"OneDbPerPool","definition","TRUE","Low","One database per resource pool","Check whether only one database is bound to resource pool '@{pool_name}'","Memory, Performance, DefaultRuleset","Only one database should be bound to a resource pool.","https://docs.microsoft.com/sql/relational-databases/resource-governor/resource-governor-resource-pool","Database",,,"SqlServer","[12.0,)",,, "OpenObjects","definition","TRUE","Low","Non-default value for 'open objects' option","Review non-default value @{open_objects} for the 'open objects' option as it has no effect and will be removed in a future version","DefaultRuleset, Performance, Configuration","The 'open objects' option has no effect and will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.","https://docs.microsoft.com/sql/database-engine/configure-windows/open-objects-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"OpenTranSleepingSessions","definition","TRUE","Medium","Sleeping sessions with open transactions","Ensure that client applications use transactions efficiently","DefaultRuleset, Performance","In any database, mismanagement of transactions often leads to contention and performance problems in systems that have many users. As the number of users that access the data increases, it becomes important to have applications that use transactions efficiently.","https://docs.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide#controlling-transactions","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"OrphanedAuditSpec","definition","TRUE","Low","Orphaned server audit specification","Connect orphaned audit specification @{spec_name} to a server audit","DefaultRuleset, Configuration, Audit","The server audit specification collects server-level action groups raised by the Extended Events feature. These actions are sent to the audit, which records them in the target. Deliting server audit may cause an orphaned audit specification. Because an audit with a matching GUID does not exist on the server instance, no audit events will be recorded.","https://learn.microsoft.com/sql/relational-databases/security/auditing/sql-server-audit-database-engine","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"OrphanedDbAuditSpec","definition","TRUE","Low","Orphaned database audit specification","Connect orphaned audit specification @{spec_name} to a server audit","DefaultRuleset, Configuration, Audit","The database audit specification collects database-level audit actions raised by the Extended Events feature. These actions are sent to the audit, which records them in the target. Deliting server audit or attaching a database that has an audit specification may cause an orphaned audit specification. Because an audit with a matching GUID does not exist on the server instance, no audit events will be recorded.","https://learn.microsoft.com/sql/relational-databases/security/auditing/sql-server-audit-database-engine","Database","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"OrphanedDbAuditSpec","override","False","Low",,,"",,,,,,"Standard, Express","[11.0, 13.0.4001)",,, "OsLoadedModules","definition","TRUE","Low","Third-party modules are loaded into SQL Server process address space","Evaluate impact of loading '@{module}' module into SQL Server process address space","DefaultRuleset, Performance, Security","Certain modules and filter drivers can be loaded into a system that is running SQL Server. In this case, you may experience performance degradation and consistency issues of SQL Server Database Engine.","https://docs.microsoft.com/troubleshoot/sql/performance/performance-consistency-issues-filter-drivers-modules","Server","Windows",,"SqlServer","[11.0,)",,, +"PageLifeExpectancy","definition","TRUE","Low","Low page life expectancy","Investigate the reason for low page life expectancy (@{page_life_expectancy})","DefaultRuleset, Performance, Memory","The low page life expectancy counter is too low. This may indicate high turnover of data in the buffer pool, which may lead to reduced performance because of high physical memory I/O.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/monitor-memory-usage","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"700", +"PageLookupsPerSec","definition","TRUE","Low","High page lookups frequency","Tune queries with high logical disk I/O to lower the page lookups per second (@{page_lookups_sec:0.##}) compared to batch requests (@{batch_request_sec:0.##})","DefaultRuleset, Performance","Page Lookups/sec indicates the number of requests per second to find a page in the buffer pool. While this identifies queries that are accessing data in memory, which is good, when divided by batch requests, a high value indicates that each batch request has many page lookups which signifies inefficeiency. Use database management objects (DMOs) to identify queries with high logical disk I/O. Tune these queries to lower disk IO, which will, in turn, lower the page lookups per second compared to batch requests. A high number of Page Lookups/sec indicates that there have been inefficient plans being generated and too many pages are getting looked up. Review table and index strategy, and ensure index and statistics maintenance plans are in place. A high number of Page Lookups/sec indicates that there have been inefficient plans being generated and too many pages are getting looked up. Review table and index strategy, and ensure index and statistics maintenance plans are in place.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-buffer-manager-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"100", +"PageSplitsPerSec","definition","TRUE","Low","High page split rate","Evaluate why the Page Splits/sec is high and investigate the use of index padding to reduce Page Splits/sec (@{page_splits_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##})","DefaultRuleset, Performance","Splitting a page is a complicated operation and the DML statement that initiated the page split generates excessive I/O, and must wait until the split operation completes. Heavily fragmented indexes may be the result of high Page Splits/sec. You can add a fill factor to your index to leave space for new records. You should consider that this will have no effect if records are added sequentially for this index, because all records will be added to the last page.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.2", "PlansUseRatioNotOptimal","definition","TRUE","Information","Cache needs to be cleared of single-use plans","Check if the plan cache needs to be cleared. Current amount of single-use plans in cache is high (@{SingleUsePlansUseRatio:P0})","DefaultRuleset, Performance, QueryOptimizer","Setting the 'Optimize for ad hoc workloads' option to 1 affects only new plans; plans that are already in the plan cache are unaffected. Make sure to check whether you need to clear the cache from the old single-use plans that may continue to remain.","https://docs.microsoft.com/sql/database-engine/configure-windows/optimize-for-ad-hoc-workloads-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.5", -"PoolMemParamSet","definition","TRUE","Low","Set 'min_memory_percent' or 'max_memory_percent' parameters","Set 'min_memory_percent' or 'max_memory_percent' for resource pool @{pool_name}","Memory, Performance, DefaultRuleset","A dedicated resource pool should have either 'min_memory_percent' parameter or 'max_memory_percent' parameter set explicitly. You should not let both parameters have default values at the same time.","https://docs.microsoft.com/sql/relational-databases/in-memory-oltp/bind-a-database-with-memory-optimized-tables-to-a-resource-pool","Database",,,"SqlServer","[12.0,)",,, +"PoolMemParamSet","definition","TRUE","Low","Set 'min_memory_percent' or 'max_memory_percent' parameters","Set 'min_memory_percent' or 'max_memory_percent' for resource pool '@{pool_name}'","Memory, Performance, DefaultRuleset","A dedicated resource pool should have either 'min_memory_percent' parameter or 'max_memory_percent' parameter set explicitly. You should not let both parameters have default values at the same time.","https://docs.microsoft.com/sql/relational-databases/in-memory-oltp/bind-a-database-with-memory-optimized-tables-to-a-resource-pool","Database",,,"SqlServer","[12.0,)",,, "PrecomputeRank","definition","TRUE","Low","Non-default value for 'precompute rank' option","Review non-default value @{precompute_rank} for the 'precompute rank' option as it has no effect and will be removed in a future version","DefaultRuleset, Configuration","The 'precompute rank' option has no effect and will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.","https://docs.microsoft.com/sql/database-engine/discontinued-database-engine-functionality-in-sql-server","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "QueryGovernorCostLimit","definition","TRUE","Information","Non-default value for 'query governor cost limit' option","Review non-default value @{query_governor_cost_limit} for the 'query governor cost limit' option","DefaultRuleset, Performance, Configuration","The 'query governor cost limit' option indicates the longest time period in seconds that a query can run. Queries with estimated run times longer than this will not run and will return an error. This can result in critical queries not running on your server.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-query-governor-cost-limit-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"RecompilationsPerSec","definition","TRUE","Low","High SQL recompilation rate","Investigate and resolve the cause of high SQL Re-Compilations/sec (@{sql_recompilations_sec:0.##}) per SQL Compilations/sec (@{sql_compilations_sec:0.##}) ","DefaultRuleset, Performance","SQL Server Recompilations/sec is the number of statement recompiles per second. This counts the number of times statement recompiles are triggered. Generally, you want the recompiles to be low. Use dynamic management views and functions to detect queries with the most recompilations. If recompilations are caused by changes in the data then they are necessary, but you should modify statements that cause unnecessary recompilations.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-sql-statistics-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.1", +"RemoteAccess","definition","TRUE","Low","Non-default value for 'remote access' option","Review non-default value @{remote_access} for the 'remote access' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'remote access' option controls the execution of stored procedures from local or remote servers. The default value for this option is 1. This grants permission to run local stored procedures from remote servers or remote stored procedures from the local server.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-remote-access-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "RemoteDAC","definition","TRUE","Low","Non-default value for 'remote admin connections' option","Review non-default value @{remote_admin_connections} for the 'remote admin connections' option","DefaultRuleset, Security, Configuration","The 'remote admin connections' option enables remote connections to the dedicated administrator connection (DAC) on a Microsoft SQL Server instance. By default, this option is disabled and allows only a local client connection to the DAC. Leave this option disabled if you want to restrict DAC access to only the local client on the stand-alone server. If your SQL Server instance is on a cluster or if you want to use the DAC connection remotely and for some troubleshooting scenarios, you should enable this option.","https://docs.microsoft.com/sql/database-engine/configure-windows/remote-admin-connections-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"RemoteLoginTimeout","definition","TRUE","Information","Non-default value for 'remote login timeout (s)' option","Review non-default value @{remote_login_timeout} for the 'remote login timeout (s)' option","DefaultRuleset, Configuration","The 'remote login timeout (s)' option specifies the number of seconds to wait before returning from a failed attempt to log in to a remote server. The default value for this option is 10.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-remote-login-timeout-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "RemoteProcTrans","definition","TRUE","Low","Non-default value for 'remote proc trans' option","Review non-default value @{remote_proc_trans} for the 'remote proc trans' option as it will be removed in a future version","DefaultRuleset, Configuration","The 'remote proc trans' option is used to protect the actions of a server-to-server procedure through a Microsoft Distributed Transaction Coordinator (MS DTC) transaction.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-remote-proc-trans-server-configuration-option","Server","Windows",,"SqlServer, ManagedInstance","[11.0,)",,, "ReplicationXPs","definition","TRUE","Low","Non-default value for 'Replication XPs' option","Set 'Replication XPs' option to default. This option is for internal use only.","DefaultRuleset, Configuration, Security","The 'Replication XPs' option opens a significant attack surface area that can be used by an attacker to gather information about the system and potentially abuse the privileges of SQL Server.","https://docs.microsoft.com/sql/database-engine/configure-windows/replication-xps-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ScanPointRevalidation","definition","TRUE","Low","Frequent scan point revalidations","Review clustered index placement to reduce Scan Point Revalidations/sec (@{scan_point_revalidations_sec:0.##})","DefaultRuleset, Performance","During a range scan on an index, there is an optimization that allows skipping the check of individual rows against a range if it is known that all rows on a page satisfy the range. Whenever a scan places a latch on a page, it tries to qualify the entire page for the range. If the check succeeds, a latch is maintained on the page for the duration of the scan (rather than on the individual rows). Another process can cause the latch to be released, however, by modifying the page. If a page latch has to be released, the scan point must be revalidated when the scan resumes. This is because all rows may no longer meet the scan criteria.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"10", +"ServerTriggerRecursion","definition","TRUE","Information","Non-default value for 'server trigger recursion' option","Review non-default value @{server_trigger_recursion} for the 'server trigger recursion' option","DefaultRuleset, Configuration","The 'server trigger recursion' option controls whether to allow server-level triggers to fire recursively. When set to 0, server-level triggers cannot be fired recursively. The default value for this option is 1.","https://docs.microsoft.com/sql/database-engine/configure-windows/server-trigger-recursion-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"ShowAdvancedOptions","definition","TRUE","Information","Option 'show advanced options' is enabled","Disable 'show advanced options' option","DefaultRuleset, Configuration","Some configuration options are designated as advanced options. By default, these options are not available for viewing and changing. When you set 'show advanced options' option to 1, you can list the advanced options by using 'sp_configure' system stored procedure. It is recommended to only use this state temporarily and switch back to 0 when done with the task that required viewing the advanced options.","https://docs.microsoft.com/sql/database-engine/configure-windows/show-advanced-options-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "SMOAndDMOXPs","definition","TRUE","Information","Option 'SMO and DMO XPs' is disabled","Enable 'SMO and DMO XPs' option","DefaultRuleset, Configuration","The 'SMO and DMO XPs' option determines whether SQL Server Management Objects (SMO) and SQL Server Distributed Management Objects (SQL-DMO) XPs are available. The default for this option is enabled to allow various tools and install packages, including SQL Server hotfixes, to work correctly.","https://docs.microsoft.com/sql/database-engine/configure-windows/smo-and-dmo-xps-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "SysAdminDefaultDatabase","definition","TRUE","Low","Sysadmin logins use non-master default database","Set sysadmin logins to use 'master' as default database","DefaultRuleset, Configuration","This check verifies whether your SQL Sever logins are members of the 'System Administrators' role that use a non-master default database. Sysadmin logins that use a non-master default database impose administrative risks in cases when user databases are dropped.",,"Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"TempDBFilesInitialSize","definition","TRUE","Medium","Tempdb data files initial size","Preallocate space for all tempdb files by setting the file size to a value large enough to accommodate the typical workload in the environment","DefaultRuleset, TempDB, Performance, DBFileConfiguration","The size and physical placement of the tempdb database can affect the performance of a system. If the size that's defined for tempdb is too small, part of the system-processing load might be taken up with autogrowing tempdb. Space preallocation prevents tempdb from expanding too often, which affects performance.","https://learn.microsoft.com/sql/relational-databases/databases/tempdb-database#optimizing-tempdb-performance-in-sql-server","Server","Windows Linux",,"SqlServer","[11.0,)",,"8", "TempDbSameVolume","definition","TRUE","Medium","Tempdb and user databases should not share volumes","Place tempdb on a separate volume. Tempdb and user databases share volume @{volume_mount_point}","DefaultRuleset, Performance, DBFileConfiguration","The tempdb system database is used for temporary objects, internal objects and row versions. Tempdb is often heavily used when queries are executed and, if it has files placed on the same volume as user database files, there can be contention for the IO resources.","https://docs.microsoft.com/sql/relational-databases/databases/tempdb-database","Database","Windows","@{not=AzureVm}","SqlServer","[11.0,)","tempdb",, "TwoDigitYearCutoff","definition","TRUE","Information","Non-default value for 'two digit year cutoff' option","Set 'two digit year cutoff' option to default","DefaultRuleset, Configuration","The 'two digit year cutoff' option is used to define the two digit year cutoff value when specifying two-digit years in place of four-digit years. Changing this to a non-default value could have unexpected results if the non-default value is inconsistent with other Microsoft SQL Server instances in your environment. This option is an advanced option and should be changed only by an experienced database administrator or certified SQL Server professional.","https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/configure-the-two-digit-year-cutoff-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "UserConnections","definition","TRUE","Information","Non-default value for 'user connections' option","Review non-default value @{user_connections} for the 'user connections' option","DefaultRuleset, Performance, Configuration","The 'user connections' option is an advanced option and should be changed only by an experienced database administrator or certified SQL Server professional. Using the 'user connections' option helps avoid overloading the server with too many concurrent connections. You can estimate the number of connections based on system and user requirements.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-user-connections-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, "UserOptions","definition","TRUE","Information","Non-default value for 'user options' option","Review non-default value @{user_options} for the 'user options' option","DefaultRuleset, Configuration","The 'user options' option defines the user option defaults, such as ARITHABORT, ANSI_WARNINGS, CONCAT_NULL_YIELDS_NULL. The bit positions in user options are identical to those in @@OPTIONS. Each connection has its own @@OPTIONS function, which represents the configuration environment. When logging in to Microsoft SQL Server, a user receives a default environment that assigns the current user options value to @@OPTIONS. Executing SET statements for user options affects the corresponding value in the session's @@OPTIONS function. All connections created after this setting is changed, receive the new value.","https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-user-options-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"WaitsForWorker","definition","TRUE","Low","High Wait for the worker","Investigate the queries and batches that are holding the threads for the longest duration and engage in fine tuning those queries/batches.Wait for the worker\Average wait time (ms) (@{wait_for_the_worker}) is greater than @{threshold}","DefaultRuleset, Performance, CPU","SQL Server Wait Statistics\Wait for Worker counter indicates average time that each SQL Server session is waiting for a worker thread to become available. If the max worker thread setting is set to default, do not increase it. If you configure a number of worker threads to a value that is greater than the default, it is almost always counterproductive and slows performance because of scheduling and resource overhead. Instead, investigate the queries and batches that are holding the threads for the longest duration and engage in fine tuning those queries/batches. Only increase this setting under very unusual circumstances and when rigorous methodical testing demonstrates that it is useful to do so.","https://learn.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WaitsLogWrite","definition","TRUE","Low","High transaction log disk response time","Improve the disk response time for the drives where the Transaction log resides, especially for write operations, log write waits\Average wait time (ms) (@{log_write_waits}) is greater than @{threshold}","DefaultRuleset, Performance","A high number of waits on Log Writes has been detected. Before any modification to a table can take place, SQL Server must write a record to the Transaction log. Any waits that occur during writes to the Transaction log will result in performance degradation. Evaluate disk performance to identify disk bottlenecks then correlate with SQL Server transactions and tune them.","https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-sql-io-performance#writelog","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WaitsNetworkIO","definition","TRUE","Low","High Network IO","Investigate the cause of high Network I/O Waits and resolve the issues that you find, network IO waits\Average wait time (ms) (@{network_io_waits}) is greater than @{threshold}","DefaultRuleset, Performance","Waits on the network I/O are frequently caused by clients not completely processing all data returned by a query or network saturation. Unprocessed results will sit in the output buffer and the SPID will show a wait type for the network I/O until all the results have been received by the client. This introduces the risk of performance degradation. Identify the queries that are waiting on the network I/O and ensure that clients are processing all the results of the query. If you have any network saturation between the server and the application, work to reduce that saturation increasing the number or speed of switches and network cards that are saturated","https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-query-async-network-io","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WaitsNonPageLatch","definition","TRUE","Low","High non-Page latch waits","Non-Page latch waits (@{non_page_latch_waits}) is greater than @{threshold}, take snapshots from sys.dm_os_latch_stats to identify the specific latch class, the identify the queries that are waiting on Non-Page latch and tune them","DefaultRuleset, Performance","The SQL Server Wait Statistics\Non-Page Latch Waits counter indicates the average time that each SQL Server session is waiting on non-page latches. Latches are used to synchronize access to cached data pages and other in-memory objects. Typically, latches are only held briefly, and latch wait times should be correspondingly small. A high number for this counter means that many processes are waiting for latch classes that are not related to buffers which, depending on the latch class, could affect your workload.","https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WaitsPageIOLatch","definition","TRUE","Low","High Page IO latch waits","Review the disk performance counters including Physical Disk: Disk Sec/Read and Disk Sec/Write and resolve the cause of the high SQL Server Page IO latch wait times (@{page_io_latch_waits} ms), and SQL Server Buffer Manager: Page Life Expectancy to investigate whether there are any disk subsystem issues, review index straegy and query plan for TOP queries with high number of logical reads","DefaultRuleset, Performance","The IO latches are a subset of BUF buffer latches that are used when the buffer and associated data page or the index page is in the middle of an I/O operation. PAGEIOLATCH wait types are used for disk-to-memory transfers and a significant wait time for these wait types suggests disk I/O subsystem issues.","https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-sql-io-performance","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WaitsPageLatch","definition","TRUE","Low","High Page Latch waits","Review latch contention, average page latch wait time is @{page_latch_waits} ms","DefaultRuleset, Performance","The SQL Server Wait Statistics\Page Latch Waits counter indicates the average time that each SQL Server session is waiting for page latches, not including IO latches. Page Latch Waits can cause a bottleneck in your system and a corresponding adverse effect on performance.","https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"500", +"WorkfilesPerSec","definition","TRUE","Low","High Workfiles Created per second","Review query performance to reduce Workfiles Created per sec (@{workfiles_created_sec:0.##})","DefaultRuleset, Performance, Memory","Workfiles are created by hash operations, and used to store temporary results for hash joins and hash aggregations. SQL Server creates a work file in tempdb when the amount of data being processed is too big to fit into the available memory used for hash operations, and generates a hash warning as a result. Determine the queries that are generating hash warnings using Extended Events.To eliminate or reduce the frequency of hash recursion and bailouts, do one of the following: Make sure that statistics exist on the columns that are being joined or grouped. If statistics exist on the columns, make sure that these are updated. Tune the query to use a different type of join, namely by adding appropriate indexes. Increase available memory on the computer. Hash recursion or bailout occurs when there is not enough memory to process queries in place and they need to spill to disk. Creating or updating the statistics on the column involved in the join is the most effective way to reduce the number of hash recursion or bailouts that occur, namely when appropriate indexes are already in place.","https://learn.microsoft.com/sql/relational-databases/event-classes/hash-warning-event-class","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.2", "WorkingSetSize","definition","TRUE","Low","Non-default value for 'set working set size' option","Review non-default value @{set_working_set_size} for the 'set working set size' option as it has no effect and will be removed in a future version","DefaultRuleset, Configuration","The 'set working set size' option has no effect and will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.","https://docs.microsoft.com/sql/database-engine/configure-windows/set-working-set-size-server-configuration-option","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,, +"WorktablesFromCache","definition","TRUE","Low","Low Worktables from Cache Ratio","Review application memory requirements, Worktables from Cache Ratio is (@{worktables_from_cache_ratio:P0})","DefaultRuleset, Performance, Memory","The Worktables From Cache Ratio counter records the percentage of worktables that were immediately available from the worktable cache. When a query execution plan is cached, the worktables needed by the plan are not dropped across multiple executions of the plan but only truncated. Because the worktable is cached, the next execution of the query is faster. When the system is low on memory, the execution plan may be removed from the cache and the associated worktables dropped as well.","https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-memory-issues","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.9", +"WorktablesPerSec","definition","TRUE","Low","High Worktables Created per second","Review table and index strategy, and ensure index and statistics maintenance plans are in place, Worktables Created/sec (@{worktables_created_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}) is greater than @{threshold:P0}","DefaultRuleset, Performance, Memory","Worktables are internal tables that are used to hold intermediate results. Worktables are generated for certain GROUP BY, ORDER BY, or UNION queries. For example, if an ORDER BY clause references columns that are not covered by any indexes, the relational engine may need to generate a worktable to sort the result set into the order requested. Worktables are also sometimes used as spools that temporarily hold the result of executing a part of a query plan. Worktables are built in tempdb and are dropped automatically when they are no longer needed.","https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object","Server","Windows Linux",,"SqlServer, ManagedInstance","[11.0,)",,"0.2", diff --git a/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceProbeStructure.svg b/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceProbeStructure.svg new file mode 100644 index 00000000..3b30bdf9 --- /dev/null +++ b/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceProbeStructure.svg @@ -0,0 +1,44 @@ +typePerformanceimplementation   NumberOfSamples?numberInterval?numberCounters   Perf object 1   Perf object 2Perf object mCounter 1 Name   Counter 2 Name   Counter n Namealiasstringinstances?   Instance 1Instance 2Instance naliasstringinstances?    \ No newline at end of file diff --git a/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceTransformStructure.svg b/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceTransformStructure.svg new file mode 100644 index 00000000..266a96b8 --- /dev/null +++ b/samples/manage/sql-assessment-api/docs/Customization/img/BasicPerformanceTransformStructure.svg @@ -0,0 +1,27 @@ +idPerformanceCounters   Counter1'simple function'Counter2   Counter3   CounterNtype'simple function'type'Function with a parameter</>'parameter nameparameter value \ No newline at end of file diff --git a/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/README.md b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/README.md index e0280098..96cd8043 100644 --- a/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/README.md +++ b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/README.md @@ -8,5 +8,6 @@ - [nameValuePairs](nameValuePairs.md) - [noData](noData.md) - [parse](parse.md) +- [performance](performance.md) - [rename](rename.md) -- [toString](toString.md) \ No newline at end of file +- [toString](toString.md) diff --git a/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/parse.md b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/parse.md index 988510ff..5100eb91 100644 --- a/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/parse.md +++ b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/parse.md @@ -1,4 +1,4 @@ -# Parse +# Data transformation: **parse** The regular expression parser extracts data from substrings of variable values that correspond to the named groups specified in regular expressions. diff --git a/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/performance.md b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/performance.md new file mode 100644 index 00000000..ddf53b0e --- /dev/null +++ b/samples/manage/sql-assessment-api/docs/Reference/DataTransformation/performance.md @@ -0,0 +1,255 @@ +# Data transformation: **performance** + +Performance probe returns a table containing multiple samples for all requested counters. A check needs some derived value. E.g. average, maximum, more complex functions. + +Use the *Performance* transform in [probe references](../../Customization/ProbeReference.md) to get derived values. Performance transform calculates specified derived value for each counter used by the check. + +![Performance transform structure diagram](../../Customization/img/BasicPerformanceTransformStructure.svg) + +## Derived value functions + +The following table lists available performance value functions. + +- **n** – number of samples for this counter +- **c₁**, **c₂** – sample values for this counter +- **t₁**, **t₂** – time stamps for samples +- **b₁**, **b₂** – sample values for *base_counter* + +| Type | Parameter | Formula | +|-------------|:--------------:|:--------------------------------------------------:| +| average | – | $\frac{1}{n}\sum_{i=1}^n c_i$ | +| delta_ratio | *base_counter* | $\frac{c_2 - c_1}{b_2 - b_1}$ | +| min/max | – | Minimum/maximum of all samples | +| rate | – | $\frac{c_2 - c_1}{t_2 - t_1}$ | +| ratio | *base_counter* | $\left(\frac{c_2}{b_2} + \frac{c_1}{b_1}\right)/2$ | + +## Example ruleset + +The following JSON object represents a complete rule set using performance counters. + +```json +{ + "schemaVersion": "1.0", + "name": "Performance Checks Example", + "version": "1.0", + "rules":[ + { + "target": { "type": "Server" }, + "id": "TotalPages", + "itemType": "definition", + "displayName": "Buffer Manager Total pages", + "description": "Use \"average\", \"min\", or \"max\" for counter type PERF_COUNTER_LARGE_RAWCOUNT(65792).", + "message": "Total pages (@{total_pages}) is greater than 0", + "condition": { + "lt": ["@total_pages", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "total_pages": "average" + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "CacheHitRatio", + "itemType": "definition", + "displayName": "Buffer Manager cache hit ratio", + "description": "Use \"ratio\" for counter type PERF_LARGE_RAW_FRACTION(537003264) and specify base PERF_LARGE_RAW_BASE(1073939712).", + "message": "Cache hit ratio (@{cache_hit_ratio:P0}) is greater than 0", + "condition": { + "lt": ["@cache_hit_ratio", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "cache_hit_ratio": { + "type": "ratio", + "base": "cache_hit_ratio_base" + } + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "LatchWaitTime", + "itemType": "definition", + "displayName": "Average Latch Wait Time", + "description": "Use \"delta_ratio\" for counter type PERF_AVERAGE_BULK(1073874176) and base PERF_LARGE_RAW_BASE(1073939712).", + "message": "Average Latch Wait Time (@{latch_wait_time}ms.) is greater than 0", + "condition": { + "lt": ["@latch_wait_time", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "latch_wait_time": { + "type": "delta_ratio", + "base": "latch_wait_time_base" + } + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "TransactionsPerSec", + "itemType": "definition", + "displayName": "Database Transactions per sec", + "description": "Use \"rate\" for counter type PERF_COUNTER_BULK_COUNT(272696576).", + "message": "Transactions per sec (@{transactions_sec:0.##}sec.) for database @{instance_name} is greater than 0", + "condition": { + "or": [{"eq": ["@instance_name", "_Total"]}, {"le": ["@transactions_sec", 0]}] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "transactions_sec": "rate" + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "TotalTransactionsPerSec", + "itemType": "definition", + "displayName": "Total Database Transactions per sec", + "description": "Use \"rate\" for counter type PERF_COUNTER_BULK_COUNT(272696576).", + "message": "Total Transactions per sec (@{transactions_sec:0.##}sec.) is greater than 0", + "condition": { + "lt": ["@transactions_sec", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "transactions_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + } + ], + "probes":{ + "PerformanceProbe": [{ + "type": "Performance", + "implementation": { + "Counters": { + "Buffer Manager": { + "Buffer cache hit ratio": "cache_hit_ratio", + "Buffer cache hit ratio base": "cache_hit_ratio_base", + "Target pages": "total_pages" + + }, + "Latches": { + "Average Latch Wait Time (ms)": "latch_wait_time", + "Average Latch Wait Time Base": "latch_wait_time_base" + }, + "Databases": { + "Transactions/sec": "transactions_sec" + } + } + } + }] + } +} +``` + +## How to use multiple performance counters in a single check + +While using multiple performance counters for different instances results might not look as expected. Take a look at the following example. + +```json +"probes": [ + { + "id": "PerformanceProbe", + "alias": "b", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate", + "lock_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } +] +``` + +The code worked as expected. The data transform returned two rows of data from the Performance probe: + +| batch_request_sec | lock_requests_sec | instance_name | +|:-----------------:|:-----------------:|:---------------------------:| +| 123s | null | ‘’ *(no instance selected)* | +| Null | 456s | ‘_Total’ | + +The condition is checked once per row and triggers a message for the first one and an error for another. + +The following JSON illustrates a solution. The Performance probe is referenced twice. The first reference gets `batch_request_sec` rate. The second one gets `lock_requests_sec` rate for the `_Total` instance. Note aliases associated with each probe reference. + +```json +"probes": [ + { + "id": "PerformanceProbe", + "alias": "b", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "PerformanceProbe", + "alias": "l", + "transform": { + "type": "performance", + "counters": { + "lock_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } +] +``` + +[Alias](../../Customization/ProbeReference.md#alias) is any alternative name for the probe. Any data variable may be prefixed with an alias or a probe id. E.g. the following names refer to the same value in an unambiguous case: + +```plain +@PerformanceProbe::batch_request_sec +@b::batch_request_sec +@batch_request_sec +``` + +Those two probe references result in the following data passed to the check: + +| b::batch_request_sec | b::instance_name | l::lock_requests_sec| l::instance_name | +|:--------------------:|:----------------:|:-------------------:|:----------------:| +| 123s | ‘’ no instance | 456s | ‘_Total’ | diff --git a/samples/manage/sql-assessment-api/docs/Reference/Probes/Performance.md b/samples/manage/sql-assessment-api/docs/Reference/Probes/Performance.md new file mode 100644 index 00000000..a49679ac --- /dev/null +++ b/samples/manage/sql-assessment-api/docs/Reference/Probes/Performance.md @@ -0,0 +1,310 @@ +# Performance probe + +**Type code:** *Performance* + +Performance probe returns values for performance counters. This probe is meant to be used with [**performance**](../DataTransformation/performance.md) transform. + +## Implementation properties + +Implementation part of the probe definition contains the following parameters. + +| Parameter | Required | Type | Default | Description | +|-----------------|:--------:|:------:|:-------:|------------------------------------------| +| numberOfSamples | Optional | number | 2 | Number of samples taken | +| interval | Optional | number | 1 | Time interval between samples in seconds | +| counters | Required | object | | The list of performance counters | + +![Performance probe structure diagram](../../Customization/img/BasicPerformanceProbeStructure.svg) + +## Performance counters list + +The list of performance counters is represented by a JSON object. Each property is for performance objects, e.g. *'Latches'*, *'Databases'*, *'Buffer Manager'*. Each performance object has a JSON object, where each property represents a performance counter. + +Counter names often contain spaces and other non-alphanumeric characters. That is why each counter must have an alias. Counter alias is the name which will be used in check conditions and messages. + +Optionally, counter may have a list of specific instances of interest. + +In the following example the probe retrieves *'Page Allocated/sec'* metric for *'Access Methods'* and returns samples as *page_allocated* values. + +```json +{ + "type": "Performance", + "implementation": { + "Counters": { + "Access Methods": { + "Pages Allocated/sec": "pages_allocated" + } + } + } +} +``` + +In the next example the probe takes only one sample for *'Free Node memory (KB)'*. + +```json +{ + "type": "Performance", + "implementation": { + "NumberOfSamples": 1, + "Counters": { + "Memory Node": { + "Free Node Memory (KB)": "free_node_memory" + } + } + } +} +``` + +In the third example the probe returns data for two performance objects *'Memory Node'* and *'Access Methods'*. For the *'Free Node Memory (KB)'* counter it returns data for *'000'* instance only. + +```json +{ + "type": "Performance", + "implementation": { + "NumberOfSamples": 1, + "Counters": { + "Memory Node": { + "Free Node Memory (KB)": { + "alias": "free_node_memory", + "instances": ["000"] + }, + "Target Node Memory (KB)": "target_node_memory" + }, + "Access Methods": { + "Pages Allocated/sec": "pages_allocated" + } + } + } +} +``` + +## Example ruleset + +The following JSON object represents a complete rule set using performance counters. + +```json +{ + "schemaVersion": "1.0", + "name": "Performance Checks Example", + "version": "1.0", + "rules":[ + { + "target": { "type": "Server" }, + "id": "TotalPages", + "itemType": "definition", + "displayName": "Buffer Manager Total pages", + "description": "Use \"average\", \"min\", or \"max\" for counter type PERF_COUNTER_LARGE_RAWCOUNT(65792).", + "message": "Total pages (@{total_pages}) is greater than 0", + "condition": { + "lt": ["@total_pages", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "total_pages": "average" + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "CacheHitRatio", + "itemType": "definition", + "displayName": "Buffer Manager cache hit ratio", + "description": "Use \"ratio\" for counter type PERF_LARGE_RAW_FRACTION(537003264) and specify base PERF_LARGE_RAW_BASE(1073939712).", + "message": "Cache hit ratio (@{cache_hit_ratio:P0}) is greater than 0", + "condition": { + "lt": ["@cache_hit_ratio", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "cache_hit_ratio": { + "type": "ratio", + "base": "cache_hit_ratio_base" + } + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "LatchWaitTime", + "itemType": "definition", + "displayName": "Average Latch Wait Time", + "description": "Use \"delta_ratio\" for counter type PERF_AVERAGE_BULK(1073874176) and base PERF_LARGE_RAW_BASE(1073939712).", + "message": "Average Latch Wait Time (@{latch_wait_time}ms.) is greater than 0", + "condition": { + "lt": ["@latch_wait_time", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "latch_wait_time": { + "type": "delta_ratio", + "base": "latch_wait_time_base" + } + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "TransactionsPerSec", + "itemType": "definition", + "displayName": "Database Transactions per sec", + "description": "Use \"rate\" for counter type PERF_COUNTER_BULK_COUNT(272696576).", + "message": "Transactions per sec (@{transactions_sec:0.##}sec.) for database @{instance_name} is greater than 0", + "condition": { + "or": [{"eq": ["@instance_name", "_Total"]}, {"le": ["@transactions_sec", 0]}] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "transactions_sec": "rate" + } + } + } + ] + }, + { + "target": { "type": "Server" }, + "id": "TotalTransactionsPerSec", + "itemType": "definition", + "displayName": "Total Database Transactions per sec", + "description": "Use \"rate\" for counter type PERF_COUNTER_BULK_COUNT(272696576).", + "message": "Total Transactions per sec (@{transactions_sec:0.##}sec.) is greater than 0", + "condition": { + "lt": ["@transactions_sec", 0] + }, + "probes": [ + { + "id": "PerformanceProbe", + "transform": { + "type": "performance", + "counters": { + "transactions_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + } + ], + "probes":{ + "PerformanceProbe": [{ + "type": "Performance", + "implementation": { + "Counters": { + "Buffer Manager": { + "Buffer cache hit ratio": "cache_hit_ratio", + "Buffer cache hit ratio base": "cache_hit_ratio_base", + "Target pages": "total_pages" + + }, + "Latches": { + "Average Latch Wait Time (ms)": "latch_wait_time", + "Average Latch Wait Time Base": "latch_wait_time_base" + }, + "Databases": { + "Transactions/sec": "transactions_sec" + } + } + } + }] + } +} +``` + +## How to use multiple performance counters in a single check + +While using multiple performance counters for different instances an issue the results might not look as expected. Take a look at the following example. + +```json +"probes": [ + { + "id": "PerformanceProbe", + "alias": "b", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate", + "lock_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } +] +``` + +The code worked as expected. The data transform returned two rows of data from the Performance probe: + +| batch_request_sec | lock_requests_sec | instance_name | +|:-----------------:|:-----------------:|:-----------------------:| +| 123s | null | ‘’ no instance selected | +| Null | 456s | ‘_Total’ | + +The condition is checked once per row and triggers a message for the first one and an error for another. + +The following JSON illustrates a solution. The Performance probe is referenced twice. The first reference gets `batch_request_sec` rate. The second one gets `lock_requests_sec` rate for the `_Total` instance. Note [aliases](../../Customization/ProbeReference.md#alias) associated with each probe reference. + +```json +"probes": [ + { + "id": "PerformanceProbe", + "alias": "b", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "PerformanceProbe", + "alias": "l", + "transform": { + "type": "performance", + "counters": { + "lock_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } +] +``` + +[Alias](../../Customization/ProbeReference.md#alias) is any alternative name for the probe. Any data variable may be prefixed with an alias or a probe id. E.g. the following names refer to the same value in an unambiguous case: + +```plain +@PerformanceProbe::batch_request_sec +@b::batch_request_sec +@batch_request_sec +``` + +Those two probe references result in the following data passed to the check: + +| b::batch_request_sec | b::instance_name | l::lock_requests_sec| l::instance_name | +|:--------------------:|:----------------:|:-------------------:|:----------------:| +| 123s | ‘’ no instance | 456s | ‘_Total’ | diff --git a/samples/manage/sql-assessment-api/docs/Reference/Probes/README.md b/samples/manage/sql-assessment-api/docs/Reference/Probes/README.md index 08c87c34..c32f54c3 100644 --- a/samples/manage/sql-assessment-api/docs/Reference/Probes/README.md +++ b/samples/manage/sql-assessment-api/docs/Reference/Probes/README.md @@ -6,9 +6,10 @@ The SQL Assessment API provides different types of probes to get data for assess - [AzGraph](./AzGraphProbe.md) - [AzMetadata](./AzMetadataProbe.md) +- [BasicPerformance](./BasicPerformance.md) - [CMD](CMDShellProbes.md) - [External](CLRProbes.md) - [PowerShell](PowerShellProbes.md) - [Registry](RegistryProbes.md) - [T-SQL](TSQLProbes.md) -- [WMI](WMIProbes.md) \ No newline at end of file +- [WMI](WMIProbes.md) diff --git a/samples/manage/sql-assessment-api/release-notes.md b/samples/manage/sql-assessment-api/release-notes.md index 8ce8d96f..9a9fcbc2 100644 --- a/samples/manage/sql-assessment-api/release-notes.md +++ b/samples/manage/sql-assessment-api/release-notes.md @@ -14,12 +14,91 @@ Download: [SMO NuGet Package](https://www.nuget.org/packages/Microsoft.SqlServer You can use GitHub issues to provide feedback to the product team. -## July 2022 - 1.1.9 +## December 2022 - 1.1.17 Version: SqlServer PowerShell module, SqlManagementObjects (SMO) package: not updated ### What's new +- New rules: + - 98 recommendations based on SQL Server error log content + - Availability database count + - Availability replica recovery health + - Columnstore indexes with large page memory model + - High SQL compilations frequency + - High cursor requests frequency + - Backup files on a separate physical location + - Database mirroring + - High deadlock frequency + - SQL Server on a domain controller + - Error log retention settings + - High free space scans rate + - Full scans vs index searches + - High latch wait time + - Excessive lazy writes + - Lock requests per batch + - Excessive lock waits + - Memory grants pending + - Non-default value for 'min server memory (MB)' option + - Non-default value for 'nested triggers' option + - High forwarded records rate + - Sleeping sessions with open transactions + - Orphaned server audit specification + - Orphaned database audit specification + - Low page life expectancy + - High page lookups frequency + - High page split rate + - High SQL recompilation rate + - Non-default value for 'remote access' option + - Non-default value for 'remote login timeout (s)' option + - Frequent scan point revalidations + - Non-default value for 'server trigger recursion' option + - Option 'show advanced options' is enabled + - Tempdb data files initial size + - High Wait for the worker + - High transaction log disk response time + - High Network IO + - High non-Page latch waits + - High Page IO latch waits + - High Page Latch waits + - High Workfiles Created per second + - Low Worktables from Cache ratio + - High Worktables Created per second +- New probes: + - [BasicPerformance](./docs/Reference/Probes/BasicPerformance.md) + - AuditSpecs + - ComputerSystem + - DatabaseBackupsMedia + - DatabaseMirroring + - ErrorLog + - ServerAudits + - ServerDatabasesProperties + - SysOpenTransactions +- New transformations: + - [Performance](./docs//Reference/Probes/BasicPerformance.md#performance-transform) counter [data transformation](./docs/Customization/DataTransformation.md) + +### Bug fixes and improvements + +- Add [join](./docs/Reference/DataTransformation/aggregate.md#join) string [aggregate function](./docs/Reference/DataTransformation/aggregate.md#aggregate-functions) new parameters: + - **distinct** specifies whether duplicates should be eliminated + - **comparison** specifies [StringComparison](https://learn.microsoft.com/dotnet/api/system.stringcomparison) used by the aggregate function +- Add **ag_replica_recovery_health** variable to the **AGConfiguration** probe +- Add **age_days** to **ErrorLogInfo** probe +- Add **remote_access**, **remote_login_timeout**, **server_trigger_recursion**, and **default_language** to **SysConfiguration** probe +- Fix warning message on missing permissions and other requirements +- Fix help link for DbSpaceAvailable check ([GitHub #1035](https://github.com/microsoft/sql-server-samples/issues/1035)) +- Fix falsely flagging deprecated features in job steps ([GitHub #1025](https://github.com/microsoft/sql-server-samples/issues/1025)) +- Fix configured to active value comparison for Max and Min server memory +- Fix duplicate messages for Azure disk checks +- Fix TF834 check triggered when no columnstore index is in use +- Remove Server target type filter from probes which work for databases + +## July 2022 - 1.1.9 + +Version: SqlServer PowerShell module: [22.0.30-preview](https://www.powershellgallery.com/packages/SqlServer/22.0.30-preview), SqlManagementObjects (SMO) package: not updated + +### What's new + - New rules: - Access check cache options ratio - Availability group listener network mode diff --git a/samples/manage/sql-assessment-api/ruleset.json b/samples/manage/sql-assessment-api/ruleset.json index 7ca2313b..04272f90 100644 --- a/samples/manage/sql-assessment-api/ruleset.json +++ b/samples/manage/sql-assessment-api/ruleset.json @@ -1,7 +1,7 @@ { "schemaVersion": "1.0", "name": "Microsoft ruleset", - "version": "1.1.9", + "version": "1.1.17", "rules": [ { "id": "AutoCreateStats", @@ -281,13 +281,27 @@ "helpLink": "https://support.microsoft.com/kb/3210239", "level": "Information", "condition": { - "in": [ - 834, - "@TraceFlag" + "or": [ + "@ColumnStoreIndexCount", + { + "in": [ + 834, + "@TraceFlag" + ] + } ] }, "probes": [ - "EnabledGlobalTraceFlags" + "EnabledGlobalTraceFlags", + { + "id": "ServerDatabasesProperties", + "transform": { + "type": "aggregate", + "map": { + "ColumnStoreIndexCount": "sum" + } + } + } ] }, { @@ -7162,8 +7176,8 @@ "MaxMemory" ], "displayName": "Max allowed memory ", - "description": "Setting the 'max server memory' value too high can cause a single instance of SQL Server to compete for memory with other SQL Server instances hosted on the same machine. However, setting this value too low could cause significant memory pressure and performance problems.", - "message": "Set 'max server memory' value to @{recommended:N0} MB or less to avoid detrimental memory pressure. Current 'max server memory' value is @{max_server_memory:N0}, which is greater than recommended", + "description": "Setting the 'max server memory (MB)' value too high can cause a single instance of SQL Server to compete for memory with other SQL Server instances hosted on the same machine. However, setting this value too low could cause significant memory pressure and performance problems.", + "message": "Set 'max server memory (MB)' value to @{recommended:N0} MB or less to avoid detrimental memory pressure. Current 'max server memory (MB)' value is @{max_server_memory:N0}, which is greater than recommended", "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options", "level": "Low", "limit": 2147483647, @@ -7291,8 +7305,8 @@ "MaxMemory" ], "displayName": "Max server memory exceeds system memory", - "description": "Setting the 'max server memory' value higher than system memory can cause SQL Server to compete for memory with the operating system and processes running on the same machine.", - "message": "Set 'max server memory' to @{recommended:N0} MB or less to avoid detrimental memory pressure. System memory of @{sysmem:N0} MB is not sufficient for current 'max server memory' setting of @{max_server_memory:N0} MB", + "description": "Setting the 'max server memory (MB)' value higher than system memory can cause SQL Server to compete for memory with the operating system and processes running on the same machine.", + "message": "Set 'max server memory (MB)' to @{recommended:N0} MB or less to avoid detrimental memory pressure. System memory of @{sysmem:N0} MB is not sufficient for current 'max server memory (MB)' setting of @{max_server_memory:N0} MB", "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options", "level": "Low", "limit": 2147483647, @@ -7475,8 +7489,8 @@ "NTFS" ], "displayName": "NTFS block size in volumes with database files <> 64KB", - "description": "A drive can be formatted with different sizes ranging from 512 bytes to 64K sizes with the default being 4KB (4096 bytes). This setting is also called as “Bytes Per Cluster”. The atomic unit of storage in SQL Server is a page which is 8KB in size. Extents are groups of eight 8 KB pages that are physically contiguous to each other for a total of 64 KB. SQL Server uses extents to store data. Hence, on a SQL Server machine the NTFS Allocation unit size hosting SQL database files (Including tempdb files) should be 64 KB.", - "message": "Set allocation unit size on volume '@{volume_mount_point}' to 64 KB. Current size is @{Output.BlockSize} bytes", + "description": "A drive can be formatted with different sizes ranging from 512 bytes to 64 KB sizes with the default being 4 KB (4096 bytes). This setting is also called as “Bytes Per Cluster”. The atomic unit of storage in SQL Server is a page which is 8KB in size. Extents are groups of eight 8 KB pages that are physically contiguous to each other for a total of 64 KB. SQL Server uses extents to store data. Hence, on a SQL Server machine the NTFS Allocation unit size hosting SQL database files (Including tempdb files) should be 64 KB.", + "message": "Set allocation unit size on volume @{volume_mount_point} to 64 KB. Current size is @{Output.BlockSize} bytes", "helpLink": "https://docs.microsoft.com/archive/blogs/docast/operating-system-best-practice-configurations-for-sql-server", "level": "Low", "BlockSize": 65536, @@ -7506,10 +7520,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } } ] @@ -7553,16 +7570,26 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { "id": "AzStorage", "params": { "path": "@DatabaseMasterFiles::volume_id" + }, + "transform": { + "type": "aggregate", + "map": { + "isBoot": "or", + "isTemp": "or" + } } } ] @@ -8364,11 +8391,11 @@ "Configuration", "Performance" ], - "displayName": "Option 'cost threshold for parallelism' set to default", + "displayName": "Non-default value for 'cost threshold for parallelism' option", "description": "The 'cost threshold for parallelism' option specifies the threshold at which SQL Server creates and runs parallel plans for queries. SQL Server creates and runs a parallel plan for a query only when the estimated cost to run a serial plan for the same query is higher than the value set in the cost threshold for parallelism. The cost refers to an estimated cost required to run the serial plan on a specific hardware configuration and is not a unit of time. The 'cost threshold for parallelism' option can be set to any value from 0 through 32767. The default value is 5.", - "message": "Set 'cost threshold for parallelism' option to @{default_cost_parallel}. Current value is @{cost_threshold_for_parallelism}", + "message": "Review non-default value @{cost_threshold_for_parallelism} for the 'cost threshold for parallelism' option", "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-cost-threshold-for-parallelism-server-configuration-option", - "level": "Medium", + "level": "Information", "default_cost_parallel": 5, "condition": { "eq": [ @@ -8719,6 +8746,46 @@ "SysConfiguration" ] }, + { + "id": "AGCount", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Availability database count", + "description": "The number of databases and availability groups hosted on a single computer (virtual or physical) depends on the hardware and workload. There is no enforced software boundary. However, having more than 100 databases on a single production computer may lead to performance issues, dependent on the workload of the databases.", + "message": "Review the number of availability databases (@{database_id})", + "level": "Information", + "helpLink": "https://learn.microsoft.com/sql/database-engine/availability-groups/windows/prereqs-restrictions-recommendations-always-on-availability", + "threshold": 100, + "condition": { + "le": [ + "@database_id", + "@threshold" + ] + }, + "probes": [ + { + "id": "AGDatabases", + "transform": { + "type": "aggregate", + "map": { + "database_id": "count" + } + } + } + ] + }, { "id": "AGDbDisjoined", "itemType": "definition", @@ -9061,6 +9128,43 @@ "AGConfiguration" ] }, + { + "id": "AGReplicasRecoveryHealth", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "AlwaysOn" + ], + "displayName": "Availability replica recovery health", + "description": "An availability group supports a replicated environment for a discrete set of user databases, known as availability databases. Each set of availability databases is hosted by an availability replica. Two types of availability replicas exist: a single primary replica, which hosts the primary databases, and one to eight secondary replicas, each of which hosts a set of secondary databases and serves as potential failover targets for the availability group. The primary replica sends transaction log records of each primary database to every secondary database. This process - known as data synchronization - occurs at the database level. Every secondary replica caches the transaction log records and then applies them to its corresponding secondary database.", + "message": "Resolve recovery health state on availability replica '@{ag_replica_server}' in availability group '@{ag_name}'", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/overview-of-always-on-availability-groups-sql-server", + "condition": { + "or": [ + { + "not": "@is_ag_replica_local" + }, + { + "eq": [ + "@ag_replica_recovery_health", + 1 + ] + } + ] + }, + "probes": [ + "AGConfiguration" + ] + }, { "id": "AGReplicasSynchronized", "itemType": "definition", @@ -9260,7 +9364,7 @@ ], "displayName": "Azure disk caching for data files", "description": "Uncached IOPS and throughput plus Cached IOPS and throughput will yield the total possible performance available from the virtual machine within the VMs limits.", - "message": "Set caching to 'ReadOnly' for disk @{name} (@{volume_mount_point}) as it is used for storing data files. Current setting: '@{caching}'", + "message": "Set caching to 'ReadOnly' for disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) as it is used for storing data files. Current setting: '@{caching}'", "helpLink": "https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies", "level": "High", "condition": { @@ -9284,10 +9388,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9340,22 +9447,16 @@ "dbId": null, "type": null }, - "transform": [ - { - "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] - }, - { - "type": "aggregate", - "group": "volume_id", - "map": { - "volume_mount_point": "join" + "transform": { + "type": "aggregate", + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" } } - ] + } }, { "id": "AzStorage", @@ -9414,10 +9515,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9532,10 +9636,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9606,7 +9713,7 @@ ], "displayName": "Use premium SSDs for SQL Server data files", "description": "Standard HDDs and SSDs have varying latencies and bandwidth and are only recommended for dev/test workloads. Production workloads should use premium SSDs.", - "message": "Move data files from @{volume_mount_point} to Premium SSD disk", + "message": "Move data files from disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) to Premium SSD disk", "helpLink": "https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage", "level": "High", "condition": { @@ -9631,10 +9738,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9695,10 +9805,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9736,7 +9849,7 @@ ], "displayName": "Azure disk caching for transaction logs", "description": "There is no performance benefit to enabling caching for the Transaction log disk, and in fact having either Read-only or Read/Write caching enabled on the log drive can decrease the amount of cache available for reads on the data drive", - "message": "Set caching to 'None' for disk @{name} (@{volume_mount_point}) as it is used for storing transaction log files. Current setting: '@{caching}'", + "message": "Set caching to 'None' for disk '@{name}' (volume @{volume_mount_point}; LUN @{lun}) as it is used for storing transaction log files. Current setting: '@{caching}'", "helpLink": "https://docs.microsoft.com/azure/azure-sql/virtual-machines/windows/performance-guidelines-best-practices-storage#data-file-caching-policies", "level": "High", "condition": { @@ -9760,10 +9873,13 @@ }, "transform": { "type": "aggregate", - "group": [ - "volume_mount_point", - "volume_id" - ] + "group": "volume_id", + "map": { + "volume_mount_point": { + "type": "join", + "comparison": "OrdinalIgnoreCase" + } + } } }, { @@ -9925,6 +10041,51 @@ "SysConfiguration" ] }, + { + "id": "ColumnstoreLargePageModel", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "displayName": "Columnstore indexes with large page memory model", + "description": "Interoperability of Columnstore indexes with large page memory model may cause severe performance issues, access violations, insufficient system memory errors, or a non-yielding Scheduler errors.", + "message": "Disable trace flag 834 when using Columnstore indexes", + "helpLink": "https://docs.microsoft.com/sql/t-sql/database-console-commands/dbcc-traceon-trace-flags-transact-sql#tf834", + "level": "Medium", + "condition": { + "or": [ + { + "not": "@ColumnStoreIndexCount" + }, + { + "not": { + "in": [ + 834, + "@TraceFlag" + ] + } + } + ] + }, + "probes": [ + "EnabledGlobalTraceFlags", + { + "id": "ServerDatabasesProperties", + "transform": { + "type": "aggregate", + "map": { + "ColumnStoreIndexCount": "sum" + } + } + } + ] + }, { "id": "CompareRunConfigured", "itemType": "definition", @@ -9962,6 +10123,71 @@ } ] }, + { + "id": "CompilationsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High SQL compilations frequency", + "description": "SQL Server will try to reuse compiled plans from the plan cache. The reuse of a plan means that a new plan does not need to be optimized and compiled and results in greater efficiency. A high proportion of compilations indicates many ad-hoc queries and will result in inefficiency. Use sp_executesql for dynamic SQL statements. In addition, investigate the possibility of changing prepared SQL and ad-hoc SQL statements to stored procedures. The FORCED PARAMETERIZATION option can be set at the database level. This makes SQL Server become much more aggressive in deciding which queries to auto-parameterize, but can potentially introduce parameter-sensitivity problems (e.g. parameter sniffing).", + "message": "Investigate the use of stored procedures, database options and server options to reduce the proportion of plan compilations to batch requests per second (@{sql_compilations_sec:0.##} / @{batch_request_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-sql-statistics-object", + "threshold": 0.1, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@sql_compilations_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "sql_compilations_sec": "rate" + } + } + } + ] + }, { "id": "ContainedDbAuthentication", "itemType": "definition", @@ -9991,6 +10217,74 @@ "SysConfiguration" ] }, + { + "id": "CursorRequestsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High cursor requests frequency", + "description": "Cursor Requests/sec is the number of cursor requests received by SQL Server. More than 20 cursor requests per 100 Batch Requests/sec on an average may indicate that the applications are designed to use cursors extensively instead of set-based operations. Look at the Cursor Requests/sec counter to get a general overview for how many cursors are being used on the system. Systems that have high CPU utilization because of small fetch sizes typically have hundreds of cursor requests per second. Redesign queries and applications to use set-based operations rather than cursors where possible.", + "message": "Determine if cursors are the most appropriate means to accomplish the processing or whether a set-based operation, which is generally more efficient, is possible, Cursor Requests/sec (@{cursor_requests_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}) is greater than @{threshold:P0}", + "helpLink": "https://techcommunity.microsoft.com/t5/sql-server-blog/increase-your-sql-server-performance-by-replacing-cursors-with/ba-p/383359", + "threshold": 0.2, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@cursor_requests_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "cursor_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + }, { "id": "CursorThreshold", "itemType": "definition", @@ -10052,6 +10346,76 @@ "SysConfiguration" ] }, + { + "id": "DbBackupMedia", + "itemType": "definition", + "target": { + "type": "Database", + "platform": "Windows", + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Backup", + "Performance", + "Configuration", + "DBConfiguration", + "DBFileConfiguration" + ], + "displayName": "Backup files on a separate physical location", + "description": "It is recommended that database backups are placed on a separate physical location or device from the database files. When your physical drive that stores your databases malfunctions or crashes, recoverability depends on the ability to access the separate drive or remote device that stored the backups in order to perform a restore. Also, putting the database and backup files on the separate devices optimizes the I/O performance for both the production use of the database and the writing of backups.", + "message": "Place backup file @{physical_device_name} on a separate physical location from the database files", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/backup-restore/back-up-and-restore-of-sql-server-databases#best-practice-recommendations", + "level": "Low", + "file_type": [ + 2, + 102 + ], + "condition": { + "or": [ + { + "not": { + "intersect": [ + "@device_type", + "@file_type" + ] + } + }, + { + "not": { + "istartswith": [ + "@physical_device_name", + "@volume_mount_point" + ] + } + } + ] + }, + "probes": [ + { + "id": "DatabaseMasterFiles", + "params": { + "type": null, + "is_percent_growth": null + }, + "transform": { + "type": "aggregate", + "group": "volume_mount_point" + } + }, + { + "id": "DatabaseBackupsMedia", + "transform": { + "type": "aggregate", + "group": "physical_device_name", + "map": { + "device_type": "array" + } + } + } + ] + }, { "id": "DbCompression", "itemType": "definition", @@ -10138,6 +10502,37 @@ } } }, + { + "id": "DbMirroring", + "itemType": "definition", + "target": { + "type": "Server", + "platform": "Windows", + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Configuration", + "Deprecated" + ], + "displayName": "Database mirroring", + "description": "Database mirroring is a solution for increasing the availability of a SQL Server database. Mirroring is implemented on a per-database basis and works only with databases that use the full recovery model. Database mirroring is deprecated and will be removed in a future version of SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. Use Always On availability groups instead.", + "message": "Plan to modify applications that currently use database mirroring as it is deprecated and will be removed in a future version", + "helpLink": "https://learn.microsoft.com/sql/database-engine/database-mirroring/database-mirroring-sql-server", + "level": "Low", + "probes": [ + { + "id": "DatabaseMirroring", + "transform": { + "type": "aggregate", + "map": { + "database_id": "count" + } + } + } + ] + }, { "id": "DbRecoveryModel", "itemType": "definition", @@ -10197,7 +10592,7 @@ "displayName": "Low free space in data files", "description": "Average available space in data files is less than the threshold.", "message": "Increase space for data files. Currently @{spaceAvailableRel:P0} is available. Threshold is set to @{threshold:P0}. Total size of data files: @{totalMB:N2} MB. Free space: @{freeMB:N2} MB", - "helpLink": "https://docs.microsoft.com/sql/relational-databases/databases/database-states", + "helpLink": "https://docs.microsoft.com/troubleshoot/sql/admin/considerations-autogrow-autoshrink#why-do-i-have-to-worry-about-disk-space-if-size-settings-are-automatically-controlled", "level": "Medium", "tags": [ "DefaultRuleset", @@ -10271,8 +10666,8 @@ ] }, "displayName": "STANDBY mode is enabled", - "description": "A Database in STANDBY mode will be online as READ ONLY, WITH RESTORE LOG allowed. If recovery is not complete, then the availability of the database might be affected. Usually log shipped secondary databases are configured to be in STANDBY mode.", - "message": "Disable STANDBY mode for database", + "description": "A database in STANDBY mode will be online as READ ONLY, WITH RESTORE LOG allowed. If recovery is not complete, then the availability of the database might be affected. Usually log shipped secondary databases are configured to be in STANDBY mode.", + "message": "Check database availability. A database is in STANDBY mode", "helpLink": "https://docs.microsoft.com/sql/t-sql/statements/restore-statements-arguments-transact-sql#with-options", "level": "Information", "tags": [ @@ -10335,6 +10730,44 @@ "DatabasesState" ] }, + { + "id": "DeadlockFrequency", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High deadlock frequency", + "description": "One or more SQL Server instances report a high frequency of deadlocked transactions. This can result in blocking, reduced concurrency, and degraded performance. Get more details on the processes that are causing deadlock between each other. To view deadlock information, the Database Engine provides monitoring tools in the form of Extended Event Sessions with the Deadlock Graph event or the trace flags 1204 or 1222 which writes more detailed information to the SQL Server Error log. Once you have identified the problematic queries you need to optimize the code, indexes, order of operations and isolation level used and required by the process.", + "message": "Investigate a high frequency of deadlocked transactions (@{number_of_deadlocks_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide?#deadlocks", + "condition": { + "not": "@number_of_deadlocks_sec" + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "number_of_deadlocks_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + }, { "id": "DisallowResultsTriggers", "itemType": "definition", @@ -10361,6 +10794,41 @@ "SysConfiguration" ] }, + { + "id": "DomainController", + "itemType": "definition", + "target": { + "type": "Server", + "platform": "Windows", + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Configuration", + "Security" + ], + "displayName": "SQL Server on a domain controller", + "description": "For security reasons, it is strongly not recommend installing SQL Server on a domain controller.", + "message": "SQL Server is installed on a domain controller. Consider migrating SQL Server to a dedicated machine", + "helpLink": "https://learn.microsoft.com/sql/sql-server/install/hardware-and-software-requirements-for-installing-sql-server#DC_support", + "level": "Medium", + "dc_roles": [ + 4, + 5 + ], + "condition": { + "not": { + "in": [ + "@Output.DomainRole", + "@dc_roles" + ] + } + }, + "probes": [ + "ComputerSystem" + ] + }, { "id": "EKMProvider", "itemType": "definition", @@ -10398,6 +10866,4554 @@ }, "enabled": false }, + { + "id": "ErrorLog109", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 109", + "description": "There are more columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in the INSERT statement.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 109, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog211", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 211", + "description": "Possible schema corruption.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "High", + "error": 211, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog232", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 232", + "description": "Arithmetic overflow error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 232, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog566", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 566", + "description": "An error occurred while writing an audit trace.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 566, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog602", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 602", + "description": "Could not find an entry for table or index. This error can occur if a stored procedure references a dropped table, or metadata is corrupted.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 602, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog603", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 603", + "description": "Could not find an entry for table or index. This error can occur if a stored procedure references a dropped table, or metadata is corrupted.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 603, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog605", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 605", + "description": "Attempt to fetch a logical page failed. This error generally signifies page or allocation corruption, and often is caused by hardware or disk device driver failure.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-605-database-engine-error", + "level": "Medium", + "error": 605, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog608", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 608", + "description": "No catalog entry found for partition. The metadata is inconsistent.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 608, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog701", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 701", + "description": "There is insufficient system memory in resource pool to run this query. Insufficient memory can be caused by a number of factors that include operating system settings, physical memory availability, other components use memory inside SQL Server, or memory limits on the current workload.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-701-database-engine-error", + "level": "Information", + "error": 701, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog802", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 802", + "description": "There is insufficient memory available in the buffer pool. This is caused when the buffer pool is full and the buffer pool cannot grow any larger.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-802-database-engine-error", + "level": "Medium", + "error": 802, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog823", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 823", + "description": "The operating system returned error to SQL Server. This error usually indicates that there is a problem with underlying storage system or the hardware or a driver that is in the path of the I/O request.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-823-database-engine-error", + "level": "Medium", + "error": 823, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog824", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 824", + "description": "SQL Server detected a logical consistency-based I/O error. This error usually indicates that there is a problem with underlying storage system or the hardware or a driver that is in the path of the I/O request.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-824-database-engine-error", + "level": "Medium", + "error": 824, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog825", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 825", + "description": "A read of a file succeeded after failing one or more times. This error indicates that the read operation had to be reissued at least one time, and indicates a major problem with the disk hardware.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-825-database-engine-error", + "level": "Medium", + "error": 825, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog829", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 829", + "description": "A page is marked as RestorePending, which may indicate disk corruption. To recover from this state, perform a restore.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "High", + "error": 829, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog832", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 832", + "description": "A page that should have been constant has changed. This usually indicates a memory failure or other hardware or operating system corruption. An external factor has caused a database page to be modified outside the normal SQL Server engine code used to change database pages.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-832-database-engine-error", + "level": "Medium", + "error": 832, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog833", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 833", + "description": "SQL Server has encountered occurrences of I/O requests taking a long time to complete. This error indicates a problem with the I/O subsystem. This problem can be caused by operating system performance issues, hardware errors, firmware errors, device driver problems, or filter driver intervention in the I/O process or storage path of database files.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-833-database-engine-error", + "level": "Information", + "error": 833, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog844", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 844", + "description": "A timeout occurred while waiting for buffer latch. A process is waiting to acquire a latch. This can occur if an I/O operation taking too long to complete.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-844-database-engine-error", + "level": "Information", + "error": 844, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog845", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 845", + "description": "A timeout occurred while waiting for buffer latch. A process was waiting to acquire a latch, but the process waited until the time limit expired and failed to acquire one. This can occur if an I/O operation takes too long to complete.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-845-database-engine-error", + "level": "Information", + "error": 845, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog846", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 846", + "description": "A timeout occurred while waiting for buffer latch. Not continuing to wait. A computer might stop responding, or a timeout or some other disruption of regular operations might occur at the same time that SQL Server writes buffer latch errors to the SQL Server error log.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-846-database-engine-error", + "level": "Information", + "error": 846, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog847", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 847", + "description": "A timeout occurred while waiting for buffer latch. Continuing to wait. A computer might stop responding, or a timeout or some other disruption of regular operations might occur at the same time that SQL Server writes buffer latch errors to the SQL Server error log.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-847-database-engine-error", + "level": "Information", + "error": 847, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog905", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 905", + "description": "A database cannot be started because it contains one or more partitioned tables or indexes. This edition of SQL Server cannot use table and index partitioning.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-905-database-engine-error", + "level": "Information", + "error": 905, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog909", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 909", + "description": "A database cannot be started because it contains one or more objects enabled with data compression or vardecimal storage format. This edition of SQL Server cannot use data compression and vardecimal storage format.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 909, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog933", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 933", + "description": "A database cannot be started because some of the database functionality is not available in this edition of SQL Server.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 933, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog934", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 934", + "description": "SQL Server cannot load a database because Change Data Capture is enabled. This edition of SQL Server does not support Change Data Capture.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 934, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog945", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 945", + "description": "A database cannot be opened due to inaccessible files or insufficient memory or disk space.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-945-database-engine-error", + "level": "Medium", + "error": 945, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog1101", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 1101", + "description": "Could not allocate a new page because of insufficient disk space.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1101-database-engine-error", + "level": "Medium", + "error": 1101, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog1105", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 1105", + "description": "Could not allocate space for an object because a filegroup is full.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1105-database-engine-error", + "level": "Medium", + "error": 1105, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog1205", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 1205", + "description": "Transaction was deadlocked on a resources with another process and has been chosen as the deadlock victim. This error indicates that resources are accessed in conflicting order on separate transactions, causing a deadlock.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-1205-database-engine-error", + "level": "Information", + "error": 1205, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog1450", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 1450", + "description": "The ALTER DATABASE command failed because the worker thread cannot be created.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 1450, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog2570", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 2570", + "description": "A column value is outside the range of possible values for the column data type.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-2570-database-engine-error", + "level": "Medium", + "error": 2570, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3041", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3041", + "description": "BACKUP failed to complete a command.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 3041, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3043", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3043", + "description": "BACKUP detected an error on page.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 3043, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3197", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3197", + "description": "I/O is frozen on a database.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 3197, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3260", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3260", + "description": "An internal buffer has become full. The server is out of memory.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3260-database-engine-error", + "level": "Information", + "error": 3260, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3266", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3266", + "description": "A backup data is incorrectly formatted. Backup sets on the media might be damaged and unusable.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 3266, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3271", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3271", + "description": "A nonrecoverable I/O error occurred. This is a general error that occurs when the operating system raises an error while performing I/O during a backup or restore operation.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3271-database-engine-error", + "level": "Information", + "error": 3271, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3313", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3313", + "description": "During redoing of a logged operation, an error occurred.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3313-database-engine-error", + "level": "Medium", + "error": 3313, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3314", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3314", + "description": "During undoing of a logged operation, an error occurred.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3314-database-engine-error", + "level": "Medium", + "error": 3314, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3316", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3316", + "description": "During undo of a logged operation, an error occurred. The row was not found.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 3316, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3409", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3409", + "description": "Performance counter shared memory setup failed.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 3409, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3414", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3414", + "description": "An error occurred during recovery, preventing a database from restarting.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3414-database-engine-error", + "level": "Medium", + "error": 3414, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3417", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3417", + "description": "Cannot recover the master database. SQL Server is unable to run.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3417-database-engine-error", + "level": "Medium", + "error": 3417, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3420", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3420", + "description": "A database snapshot has failed an IO operation and is marked suspect.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 3420, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3431", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3431", + "description": "Could not recover a database because of unresolved transaction outcomes.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3431-database-engine-error", + "level": "Medium", + "error": 3431, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3437", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3437", + "description": "An error occurred while recovering a database. Unable to connect to Distributed Transaction Coordinator to check the completion status of a transaction.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3437-database-engine-error", + "level": "Medium", + "error": 3437, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3452", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3452", + "description": "Recovery of a database detected possible identity value inconsistency in a table.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3452-database-engine-error", + "level": "Information", + "error": 3452, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3456", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3456", + "description": "Could not redo log record.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3456-database-engine-error", + "level": "Medium", + "error": 3456, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3619", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3619", + "description": "Could not write a checkpoint record because the log is out of space. The transaction log is out of disk space.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3619-database-engine-error", + "level": "Medium", + "error": 3619, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog3859", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 3859", + "description": "The system catalog was updated directly. This error indicates a user initiated changes to system tables. Manually updating system tables is not supported.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-3859-database-engine-error", + "level": "Medium", + "error": 3859, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog5105", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 5105", + "description": "A file activation error occurred. The physical file name may be incorrect.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 5105, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog5180", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 5180", + "description": "Could not open File Control Bank for invalid file. A query or operation may fail when an invalid file ID is referenced.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-5180-database-engine-error", + "level": "Medium", + "error": 5180, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog5243", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 5243", + "description": "An inconsistency was detected during an internal operation. SQL Server detected a structural inconsistency in an in-memory storage engine structure.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-5243-database-engine-error", + "level": "Information", + "error": 5243, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog7105", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 7105", + "description": "A large object data referenced by a database page row cannot be accessed. This is usually caused by transactions that can read uncommitted data on a data page.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-7105-database-engine-error", + "level": "Information", + "error": 7105, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog7359", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 7359", + "description": "The OLE DB provider for a linked server reported a change in schema version between compile time and run time.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 7359, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8621", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8621", + "description": "The query processor ran out of stack space during query optimization. The size of the expanded query is the most likely cause of the error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8621-database-engine-error", + "level": "Medium", + "error": 8621, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8628", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8628", + "description": "A timeout occurred while waiting to optimize the query.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 8628, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8642", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8642", + "description": "The query processor could not start the necessary thread resources for parallel query execution.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8642-database-engine-error", + "level": "Medium", + "error": 8642, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8645", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8645", + "description": "A timeout occurred while waiting for memory resources to execute the query.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8645-database-engine-error", + "level": "Information", + "error": 8645, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8909", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8909", + "description": "A page contains an incorrect page ID in its page header.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 8909, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog8966", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 8966", + "description": "Unable to read and latch page.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-8966-database-engine-error", + "level": "Information", + "error": 8966, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9002", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9002", + "description": "A database transaction log is full.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9002-database-engine-error", + "level": "Medium", + "error": 9002, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9004", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9004", + "description": "An error was encountered while processing the log during rollback, recovery, or replication. This could indicate an error detected by the operating system or an internal consistency error detected by SQL Server.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9004-database-engine-error", + "level": "High", + "error": 9004, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9642", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9642", + "description": "An error occurred in a Service Broker/Database Mirroring transport connection endpoint.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 9642, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9691", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9691", + "description": "An endpoint has stopped listening for connections.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 9691, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9692", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9692", + "description": "An endpoint cannot listen on a port because it is in use by another process.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-9692-database-engine-error", + "level": "Information", + "error": 9692, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog9693", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 9693", + "description": "An endpoint cannot listen for connections due to an error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 9693, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17065", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17065", + "description": "This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17065-database-engine-error", + "level": "Medium", + "error": 17065, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17066", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17066", + "description": "This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17066-database-engine-error", + "level": "Medium", + "error": 17066, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17067", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17067", + "description": "This error can be caused by transient, timing-related errors, or by in-memory or on-disk data corruption.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17067-database-engine-error", + "level": "Medium", + "error": 17067, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17194", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17194", + "description": "This error indicates that the client has closed the connection. This error could occur because the connection timeout has expired.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17194-database-engine-error", + "level": "Medium", + "error": 17194, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17204", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17204", + "description": "Could not open a file. SQL Server was unable to open the file because of the operating system error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17204-database-engine-error", + "level": "Information", + "error": 17204, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17207", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17207", + "description": "An operating system error occurred while creating or opening a file. SQL Server was unable to open the file because of the operating system error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17207-database-engine-error", + "level": "Information", + "error": 17207, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17659", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17659", + "description": "A system table has been updated directly and cache coherence may not have been maintained. This error indicates a user initiated changes to system tables. Manually updating system tables is not supported.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17659-database-engine-error", + "level": "High", + "error": 17659, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17806", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17806", + "description": "Security Support Provider Interface handshake failed while establishing a connection with integrated security.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 17806, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17832", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17832", + "description": "The login packet used to open the connection is structurally invalid. This error could occur because the packet was created improperly or because the packet was damaged during transmission.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17832-database-engine-error", + "level": "Information", + "error": 17832, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17884", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17884", + "description": "New queries assigned to process have not been picked up by a worker thread.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17884-database-engine-error", + "level": "Medium", + "error": 17884, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17887", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17887", + "description": "An IO Completion Listener appears to be non-yielding. This error indicates that there is a possible problem with the I/O Completion Port Listener when executing the I/O Completion routine for a network read/write event.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17887-database-engine-error", + "level": "Medium", + "error": 17887, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17888", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17888", + "description": "All schedulers on a node appear deadlocked due to a large number of waiting worker threads.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 17888, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog17890", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 17890", + "description": "A significant part of SQL Server process memory has been paged out. This may result in a performance degradation.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/mssqlserver-17890-database-engine-error", + "level": "Medium", + "error": 17890, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog18056", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 18056", + "description": "The client was unable to reuse a session, which had been reset for connection pooling. This error may have been caused by an earlier operation failing.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 18056, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog18204", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 18204", + "description": "A backup device failed because of the operating system error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "High", + "error": 18204, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog18272", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 18272", + "description": "During restore restart, an I/O error occurred on a checkpoint file.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 18272, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog19034", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 19034", + "description": "Cannot start C2 audit trace.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 19034, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog26023", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 26023", + "description": "SQL Server TCP provider failed to listen on a port. TCP port is already in use.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 26023, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog26024", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 26024", + "description": "SQL Server TCP provider failed to listen on a port.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 26024, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog26037", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 26037", + "description": "SQL Server Network Interface library could not register the Service Principal Name (SPN) for SQL Server service. Failure to register an SPN may cause integrated authentication to fall back to NTLM instead of Kerberos.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 26037, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog26038", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 26038", + "description": "SQL Server Network Interface library could not register the Service Principal Name (SPN) for SQL Server service. This SPN should be deregistered manually to avoid client authentication errors.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 26038, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog28034", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 28034", + "description": "Connection handshake failed. A login does not have CONNECT permission on the endpoint.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 28034, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog28036", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 28036", + "description": "Connection handshake failed. The certificate used by the endpoint was not found.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Medium", + "error": 28036, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog28047", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 28047", + "description": "A login attempt failed with error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 28047, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog28048", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 28048", + "description": "A login attempt by an user failed with error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/errors-events/database-engine-events-and-errors", + "level": "Information", + "error": 28048, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog35201", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 35201", + "description": "A connection timeout has occurred while attempting to establish a connection to an availability replica. Either a networking or firewall issue exists, or the endpoint address provided for the replica is not the database mirroring endpoint.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Information", + "error": 35201, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog35204", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 35204", + "description": "The connection between server instances has been disabled because the database mirroring endpoint was either disabled or stopped.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Information", + "error": 35204, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog35206", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 35206", + "description": "A connection timeout has occurred on a previously established connection to an availability replica. Either a networking or a firewall issue exists or the availability replica has transitioned to the resolving role.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Information", + "error": 35206, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog35207", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 35207", + "description": "Connection attempt on an availability group failed because of error.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Information", + "error": 35207, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog35217", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 35217", + "description": "The thread pool for AlwaysOn Availability Groups was unable to start a new worker thread because there are not enough available worker threads.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Medium", + "error": 35217, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog41142", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 41142", + "description": "The availability replica for an availability group cannot become the primary replica. One or more databases are not synchronized or have not joined the availability group.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Medium", + "error": 41142, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLog41144", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Database engine error 41144", + "description": "A local availability replica is in a failed state. The replica failed to read or update the persisted configuration data.", + "message": "Database engine error @{error} occurred @{error_count} times in the last @{history_days} days. Last occurrence at @{last_occurrence}.", + "helpLink": "https://docs.microsoft.com/sql/database-engine/availability-groups/windows/troubleshoot-always-on-availability-groups-configuration-sql-server", + "level": "Medium", + "error": 41144, + "history_days": 7, + "condition": { + "or": [ + { + "ne": [ + "@errorId", + "@error" + ] + }, + { + "eq": [ + "error_count", + 0 + ] + } + ] + }, + "probes": [ + { + "id": "ErrorLog", + "params": { + "history_days": "@history_days", + "max_log_size_mb": 50, + "language": null + } + } + ] + }, + { + "id": "ErrorLogAge", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Error log retention settings", + "description": "The SQL Server error log contains lots of information that is generated by the SQL Server. The error log file is initialized every time that the instance of SQL Server is started. Specify the maximum number of archived error log files created before they are recycled. The default is 6, not including the current one.", + "message": "Revise error log retention settings. Error log contains less than @{threshold} days of history", + "helpLink": "https://learn.microsoft.com/troubleshoot/sql/admin/manage-error-log", + "level": "Low", + "threshold": 14, + "condition": { + "gt": [ + "@age_days", + "@threshold" + ] + }, + "probes": [ + { + "id": "ErrorLogInfo", + "transform": { + "type": "aggregate", + "map": { + "age_days": "max" + } + } + } + ] + }, { "id": "FileMaxSize", "itemType": "definition", @@ -10528,20 +15544,96 @@ "Configuration" ], "displayName": "Non-default value for 'fill factor' option", - "description": "The 'fill factor' option controls the default fill factor that is used when a new index is created or rebuilt. The default value is 0, which means that the leaf level of the index will be filled with the highest possible number of rows. This option is an advanced option and should be changed only by an experienced database administrator or certified SQL Server professional.", - "message": "Review non-default value @{fill_factor} for the 'fill factor' option", + "description": "The 'fill factor' option controls the default fill factor that is used when a new index is created or rebuilt. The default value is 0, which means that the leaf level of the index will be filled with the highest possible number of rows.", + "message": "Review non-default value @{fill_factor} for the 'fill factor' option. A low, nonzero 'fill factor' option value can decrease database read performance", "helpLink": "https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/configure-the-fill-factor-server-configuration-option", "level": "Information", + "threshold": 80, "condition": { - "eq": [ - "@fill_factor", - 0 + "or": [ + { + "eq": [ + "@fill_factor", + 0 + ] + }, + { + "ge": [ + "@fill_factor", + "@threshold" + ] + } ] }, "probes": [ "SysConfiguration" ] }, + { + "id": "FreeSpaceScansPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High free space scans rate", + "description": "Inserts into heaps require SQL Server to perform free space scans to identify pages with free space to insert rows. An insert into a heap often spends time searching for a location to insert the new row. On the other hand the insert into a clustered table does not have to spend any time searching for space. In most cases it is best to start with a clustered index on every table. There are occasional instances where this is not optimal, but it is extremely rare that the existence of a clustered index hurts performance and it usually helps. Test your workload to ensure that adding a clustered index has no detrimental effects.", + "message": "Add clustered indexes to heaps and reduce FreeSpace Scans/sec (@{freespace_scans_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}), which is greater than @{threshold:P0}", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/indexes/heaps-tables-without-clustered-indexes?#when-not-to-use-a-heap", + "threshold": 0.1, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@freespace_scans_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "freespace_scans_sec": "rate" + } + } + } + ] + }, { "id": "FtCrawlBandwidthMax", "itemType": "definition", @@ -10666,6 +15758,81 @@ "SysConfiguration" ] }, + { + "id": "FullScansVsIndexSearches", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Full scans vs index searches", + "description": "Index searches are preferable to index and table scans. For OLTP applications, optimize for more index searches and less scans. An ideal ratio on a typical system would be approximately 1 full scan for every 1000 index searches. Index searches are preferable to full scans because full scans cause excessive disk I/O and consume more CPU resources. Execution plans or extended events can be used to identify which Transact-SQL statements perform scans. Review table and index strategy, and ensure index and statistics maintenance plans are in place.", + "message": "Reduce the number of Full Scans (@{full_scans_sec:0.##}) versus Index Searches (@{index_searches_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/sql-server-index-design-guide?#General_Design", + "threshold": 1000, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "ge": [ + "@index_searches_sec", + { + "mul": [ + "@full_scans_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "index_searches_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfC", + "transform": { + "type": "performance", + "counters": { + "full_scans_sec": "rate" + } + } + } + ] + }, { "id": "FullTextDefaultLang", "itemType": "definition", @@ -10906,6 +16073,112 @@ } ] }, + { + "id": "LatchWaitTimePerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High latch wait time", + "description": "The storage engine must ensure that no other task modifies the contents of a memory structure (like a buffer page) while it is being modified by the current task. It does this by acquiring a latch, updating the row in memory (or any other structure protected by a latch), and then releasing the latch. A latch wait indicates the number of times that a latch could not be granted immediately and the task needed to wait.", + "message": "Investigate and resolve the cause of high average Latch Wait Times (@{total_latch_wait_time_ms:0.##} ms for @{latch_waits_sec:0.##} per second)", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention", + "threshold": 10, + "condition": { + "or": [ + { + "le": [ + "@latch_waits_sec", + 0 + ] + }, + { + "le": [ + { + "div": [ + "@total_latch_wait_time_ms", + "@latch_waits_sec" + ] + }, + "@threshold" + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "total_latch_wait_time_ms": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "latch_waits_sec": "rate" + } + } + } + ] + }, + { + "id": "LazyWritesPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Excessive Lazy Writes", + "description": "This counter tracks how many times a second that the Lazy Writer process is moving dirty pages from the buffer to disk in order to free up buffer space. Typically, this should not be more than 20 per second. Ideally, it should be close to zero. This issue usually indicates memory pressure. Even if you can add physical memory to the server to mitigate this issue in the short-term, it is better to find the root cause, commonly inefficient queries, and troubleshoot those. Improving the indexing design, reducing cursor usage, and avoiding scans can significantly improve the value for this counter.", + "message": "Find and troubleshoot the cause of excessive Lazy writes per second (@{lazy_writes:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/writing-pages", + "threshold": 20, + "condition": { + "lt": [ + "@lazy_writes", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "lazy_writes": { + "type": "rate" + } + } + } + } + ] + }, { "id": "LockedPagesInMemory", "itemType": "definition", @@ -10966,6 +16239,116 @@ "SysDmOsSysInfo" ] }, + { + "id": "LockRequestsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Lock requests per batch", + "description": "Lock Requests/sec reports the number of requests for a type of lock per second. A Lock Requests/sec greater than 500 when compared to Batch Request/sec indicates that batches are acquiring a large number of locks. This suggests inefficient queries. The risk is that blocking may occur. Review high-read queries. In addition, try to reduce the number of reads by tuning your application, the queries executed by the application and the indexing strategy. You can reduce the locks by changing the transaction isolation level, where appropriate.", + "message": "Review the design of high-read queries and attempt to reduce the number of reads (@{lock_requests_sec:0.##} lock requests for @{batch_request_sec:0.##} batch requests)", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide?#Lock_Engine", + "threshold": 500, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@lock_requests_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "lock_requests_sec": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + }, + { + "id": "LockWaitTime", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Excessive Lock Waits", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "Excessive locking reduces overall throughput and increases the latency observed by users. Investigate the cause of lock contention and reduce this as much as possible to resolve lock wait issues. The following methods can be used to reduce lock contention and increase overall throughput: review index straegy, leverage Read Committed Snapshot and Snapshot Isolation whenever possible, avoid situations in which many processes are attempting to perform updates or inserts on the same data page, avoid transactions that include user interaction, keep transactions that modify data as short as possible, keep transactions in one batch, avoid pessimistic locking hints such as holdlock whenever possible, and reduce the fill factor when creating an index to help diminish the chance of random updates requiring the same page.", + "message": "Investigate the cause of excessive Lock Waits (@{lock_wait_time_ms:0.##} ms.) and resolve lock contention", + "helpLink": "http://support.microsoft.com/kb/75722", + "threshold": 500, + "condition": { + "le": [ + "@lock_wait_time_ms", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "lock_wait_time_ms": { + "type": "rate", + "instance": "_Total" + } + } + } + } + ] + }, { "id": "MaxFTCrawlRange", "itemType": "definition", @@ -11089,6 +16472,75 @@ "DatabaseConfiguration" ] }, + { + "id": "MemoryGrantsPending", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Memory grants pending", + "description": "Memory Grants Pending records the number of connections that are waiting for memory before they can begin processing a memory intensive query such as a sort or hash operation. Connections that wait in this state for a long enough time will eventually get an 8645 error (A time out occurred while waiting for memory resources to execute the query. Rerun the query). If this counter remains above zero for a significant period of time, you will need to determine which queries are doing sorts or hashes and will then need to tune them to see if they can utilize a more efficient plan.", + "message": "Tune queries to reduce Memory Grants Pending (@{memory_grants_pending})", + "helpLink": "https://techcommunity.microsoft.com/t5/sql-server-blog/understanding-sql-server-memory-grant/ba-p/383595", + "condition": { + "le": [ + "@memory_grants_pending", + 0 + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "memory_grants_pending": "max" + } + } + } + ] + }, + { + "id": "MinServerMemory", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Non-default value for 'min server memory (MB)' option", + "description": "Use the 'min server memory (MB)' option to guarantee a minimum amount of memory available to the SQL Server Memory Manager. The default value for this option is 0. Leave this option at the default value if the SQL Server instance is on a dedicated computer or node that has no other applications or SQL Server instances running concurrently with it.", + "message": "Review non-default value @{min_server_memory} for the 'min server memory (MB)' option", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/server-memory-server-configuration-options", + "level": "Information", + "condition": { + "eq": [ + "@min_server_memory", + 0 + ] + }, + "probes": [ + "SysConfiguration" + ] + }, { "id": "MoreIndexesThanCols", "itemType": "definition", @@ -11134,6 +16586,97 @@ "TablesInformation" ] }, + { + "id": "NestedTriggers", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Non-default value for 'nested triggers' option", + "description": "The 'nested triggers' option controls whether an AFTER trigger can cascade. When set to 0, AFTER triggers cannot cascade. The default value for this option is 1.", + "message": "Review non-default value @{nested_triggers} for the 'nested triggers' option", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-nested-triggers-server-configuration-option", + "level": "Information", + "condition": "@nested_triggers", + "probes": [ + "SysConfiguration" + ] + }, + { + "id": "OForwardedRecordsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High forwarded records rate", + "description": "Forwarded records occur when a data record in a heap increases in size and the record's current page does not have the space to store the size increase. The record is moved to a new location, becoming a forwarded record, and the forwarding record is left in the original location to point to the real location of the record. The forwarded record points back to the forwarding record in case its location ever needs to change again. If the table experiences several forward records may indicate the table is fragmented and scanning through the table is very inefficient. Review the table index strategy. Forwarded records can be avoided by:Evaluating creating clustered indexes on heaps. Using default values so that an update does not result in a longer row that is the root cause of the forwarded records. Using a fixed size data type such as CHAR instead of VARCHAR. ALTER TABLE … REBUILD to remove heap fragmentation.", + "message": "Evaluate index design to reduce Forwarded Records/sec (@{forwarded_records_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}), which is greater than @{threshold:P0}", + "helpLink": "https://techcommunity.microsoft.com/t5/sql-server-blog/knowing-about-forwarded-records-can-help-diagnose-hard-to-find/ba-p/383189", + "threshold": 0.1, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@forwarded_records_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "forwarded_records_sec": "rate" + } + } + } + ] + }, { "id": "OneDbPerPool", "itemType": "definition", @@ -11149,7 +16692,7 @@ ], "displayName": "One database per resource pool", "description": "Only one database should be bound to a resource pool.", - "message": "Check whether only one database is bound to resource pool @{pool_name}", + "message": "Check whether only one database is bound to resource pool '@{pool_name}'", "helpLink": "https://docs.microsoft.com/sql/relational-databases/resource-governor/resource-governor-resource-pool", "condition": { "or": [ @@ -11214,6 +16757,157 @@ "SysConfiguration" ] }, + { + "id": "OpenTranSleepingSessions", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Sleeping sessions with open transactions", + "description": "In any database, mismanagement of transactions often leads to contention and performance problems in systems that have many users. As the number of users that access the data increases, it becomes important to have applications that use transactions efficiently.", + "message": "Ensure that client applications use transactions efficiently", + "helpLink": "https://docs.microsoft.com/sql/relational-databases/sql-server-transaction-locking-and-row-versioning-guide#controlling-transactions", + "level": "Medium", + "condition": { + "eq": [ + "@session_id", + 0 + ] + }, + "probes": [ + { + "id": "SysOpenTranSessions", + "params": { + "user_session": 1, + "status": "sleeping", + "last_request_end_min": 15 + }, + "transform": { + "type": "aggregate", + "map": { + "session_id": "count" + } + } + } + ] + }, + { + "id": "OrphanedAuditSpec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Configuration", + "Audit" + ], + "displayName": "Orphaned server audit specification", + "description": "The server audit specification collects server-level action groups raised by the Extended Events feature. These actions are sent to the audit, which records them in the target. Deliting server audit may cause an orphaned audit specification. Because an audit with a matching GUID does not exist on the server instance, no audit events will be recorded.", + "message": "Connect orphaned audit specification @{spec_name} to a server audit", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/security/auditing/sql-server-audit-database-engine", + "level": "Low", + "condition": { + "iin": [ + "@server_audit_guid", + "@audit_guid" + ] + }, + "probes": [ + { + "id": "ServerAudits", + "transform": [ + { + "type": "aggregate", + "map": { + "audit_guid": "array" + } + }, + { + "type": "noData", + "define": { + "audit_guid": [] + } + } + ] + }, + "AuditSpecs" + ] + }, + { + "id": "OrphanedDbAuditSpec", + "itemType": "definition", + "target": { + "type": "Database", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Configuration", + "Audit" + ], + "displayName": "Orphaned database audit specification", + "description": "The database audit specification collects database-level audit actions raised by the Extended Events feature. These actions are sent to the audit, which records them in the target. Deliting server audit or attaching a database that has an audit specification may cause an orphaned audit specification. Because an audit with a matching GUID does not exist on the server instance, no audit events will be recorded.", + "message": "Connect orphaned audit specification @{spec_name} to a server audit", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/security/auditing/sql-server-audit-database-engine", + "level": "Low", + "condition": { + "iin": [ + "@server_audit_guid", + "@audit_guid" + ] + }, + "probes": [ + { + "id": "ServerAudits", + "transform": [ + { + "type": "aggregate", + "map": { + "audit_guid": "array" + } + }, + { + "type": "noData", + "define": { + "audit_guid": [] + } + } + ] + }, + "AuditSpecs" + ] + }, + { + "id": "OrphanedDbAuditSpec", + "itemType": "override", + "targetFilter": { + "engineEdition": "Standard, Express", + "version": "[11.0, 13.0.4001)" + }, + "enabled": false + }, { "id": "OsLoadedModules", "itemType": "definition", @@ -11280,6 +16974,176 @@ "OsLoadedModules" ] }, + { + "id": "PageLifeExpectancy", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance", + "Memory" + ], + "displayName": "Low page life expectancy", + "description": "The low page life expectancy counter is too low. This may indicate high turnover of data in the buffer pool, which may lead to reduced performance because of high physical memory I/O.", + "message": "Investigate the reason for low page life expectancy (@{page_life_expectancy})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/monitor-memory-usage", + "threshold": 700, + "condition": { + "ge": [ + "@page_life_expectancy", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "page_life_expectancy": "average" + } + } + } + ] + }, + { + "id": "PageLookupsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High page lookups frequency", + "description": "Page Lookups/sec indicates the number of requests per second to find a page in the buffer pool. While this identifies queries that are accessing data in memory, which is good, when divided by batch requests, a high value indicates that each batch request has many page lookups which signifies inefficeiency. Use database management objects (DMOs) to identify queries with high logical disk I/O. Tune these queries to lower disk IO, which will, in turn, lower the page lookups per second compared to batch requests. A high number of Page Lookups/sec indicates that there have been inefficient plans being generated and too many pages are getting looked up. Review table and index strategy, and ensure index and statistics maintenance plans are in place. A high number of Page Lookups/sec indicates that there have been inefficient plans being generated and too many pages are getting looked up. Review table and index strategy, and ensure index and statistics maintenance plans are in place.", + "message": "Tune queries with high logical disk I/O to lower the page lookups per second (@{page_lookups_sec:0.##}) compared to batch requests (@{batch_request_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-buffer-manager-object", + "threshold": 100, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@page_lookups_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "page_lookups_sec": "rate" + } + } + } + ] + }, + { + "id": "PageSplitsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High page split rate", + "description": "Splitting a page is a complicated operation and the DML statement that initiated the page split generates excessive I/O, and must wait until the split operation completes. Heavily fragmented indexes may be the result of high Page Splits/sec. You can add a fill factor to your index to leave space for new records. You should consider that this will have no effect if records are added sequentially for this index, because all records will be added to the last page.", + "message": "Evaluate why the Page Splits/sec is high and investigate the use of index padding to reduce Page Splits/sec (@{page_splits_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object", + "threshold": 0.2, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@page_splits_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "page_splits_sec": "rate" + } + } + } + ] + }, { "id": "PlansUseRatioNotOptimal", "itemType": "definition", @@ -11336,7 +17200,7 @@ ], "displayName": "Set 'min_memory_percent' or 'max_memory_percent' parameters", "description": "A dedicated resource pool should have either 'min_memory_percent' parameter or 'max_memory_percent' parameter set explicitly. You should not let both parameters have default values at the same time.", - "message": "Set 'min_memory_percent' or 'max_memory_percent' for resource pool @{pool_name}", + "message": "Set 'min_memory_percent' or 'max_memory_percent' for resource pool '@{pool_name}'", "helpLink": "https://docs.microsoft.com/sql/relational-databases/in-memory-oltp/bind-a-database-with-memory-optimized-tables-to-a-resource-pool", "condition": { "or": [ @@ -11439,6 +17303,107 @@ "SysConfiguration" ] }, + { + "id": "RecompilationsPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "High SQL recompilation rate", + "description": "SQL Server Recompilations/sec is the number of statement recompiles per second. This counts the number of times statement recompiles are triggered. Generally, you want the recompiles to be low. Use dynamic management views and functions to detect queries with the most recompilations. If recompilations are caused by changes in the data then they are necessary, but you should modify statements that cause unnecessary recompilations.", + "message": "Investigate and resolve the cause of high SQL Re-Compilations/sec (@{sql_recompilations_sec:0.##}) per SQL Compilations/sec (@{sql_compilations_sec:0.##}) ", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-sql-statistics-object", + "threshold": 0.1, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@sql_recompilations_sec", + { + "mul": [ + "@sql_compilations_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "perfA", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "sql_recompilations_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfC", + "transform": { + "type": "performance", + "counters": { + "sql_compilations_sec": "rate" + } + } + } + ] + }, + { + "id": "RemoteAccess", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Non-default value for 'remote access' option", + "description": "The 'remote access' option controls the execution of stored procedures from local or remote servers. The default value for this option is 1. This grants permission to run local stored procedures from remote servers or remote stored procedures from the local server.", + "message": "Review non-default value @{remote_access} for the 'remote access' option as it will be removed in a future version", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-remote-access-server-configuration-option", + "level": "Low", + "condition": "@remote_access", + "probes": [ + "SysConfiguration" + ] + }, { "id": "RemoteDAC", "itemType": "definition", @@ -11471,6 +17436,37 @@ "SysConfiguration" ] }, + { + "id": "RemoteLoginTimeout", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Non-default value for 'remote login timeout (s)' option", + "description": "The 'remote login timeout (s)' option specifies the number of seconds to wait before returning from a failed attempt to log in to a remote server. The default value for this option is 10.", + "message": "Review non-default value @{remote_login_timeout} for the 'remote login timeout (s)' option", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/configure-the-remote-login-timeout-server-configuration-option", + "level": "Information", + "condition": { + "eq": [ + "@remote_login_timeout", + 10 + ] + }, + "probes": [ + "SysConfiguration" + ] + }, { "id": "RemoteProcTrans", "itemType": "definition", @@ -11528,6 +17524,104 @@ "SysConfiguration" ] }, + { + "id": "ScanPointRevalidation", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "Performance" + ], + "displayName": "Frequent scan point revalidations", + "description": "During a range scan on an index, there is an optimization that allows skipping the check of individual rows against a range if it is known that all rows on a page satisfy the range. Whenever a scan places a latch on a page, it tries to qualify the entire page for the range. If the check succeeds, a latch is maintained on the page for the duration of the scan (rather than on the individual rows). Another process can cause the latch to be released, however, by modifying the page. If a page latch has to be released, the scan point must be revalidated when the scan resumes. This is because all rows may no longer meet the scan criteria.", + "message": "Review clustered index placement to reduce Scan Point Revalidations/sec (@{scan_point_revalidations_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object", + "threshold": 10, + "condition": { + "le": [ + "@scan_point_revalidations_sec", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "scan_point_revalidations_sec": { + "type": "rate" + } + } + } + } + ] + }, + { + "id": "ServerTriggerRecursion", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Non-default value for 'server trigger recursion' option", + "description": "The 'server trigger recursion' option controls whether to allow server-level triggers to fire recursively. When set to 0, server-level triggers cannot be fired recursively. The default value for this option is 1.", + "message": "Review non-default value @{server_trigger_recursion} for the 'server trigger recursion' option", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/server-trigger-recursion-server-configuration-option", + "level": "Information", + "condition": "@server_trigger_recursion", + "probes": [ + "SysConfiguration" + ] + }, + { + "id": "ShowAdvancedOptions", + "itemType": "definition", + "target": { + "type": "Server", + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)", + "platform": [ + "Windows", + "Linux" + ] + }, + "tags": [ + "DefaultRuleset", + "Configuration" + ], + "displayName": "Option 'show advanced options' is enabled", + "description": "Some configuration options are designated as advanced options. By default, these options are not available for viewing and changing. When you set 'show advanced options' option to 1, you can list the advanced options by using 'sp_configure' system stored procedure. It is recommended to only use this state temporarily and switch back to 0 when done with the task that required viewing the advanced options.", + "message": "Disable 'show advanced options' option", + "helpLink": "https://docs.microsoft.com/sql/database-engine/configure-windows/show-advanced-options-server-configuration-option", + "level": "Information", + "condition": { + "eq": [ + "@show_advanced_options", + 0 + ] + }, + "probes": [ + "SysConfiguration" + ] + }, { "id": "SMOAndDMOXPs", "itemType": "definition", @@ -11589,6 +17683,65 @@ } ] }, + { + "id": "TempDBFilesInitialSize", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "tags": [ + "DefaultRuleset", + "TempDB", + "Performance", + "DBFileConfiguration" + ], + "displayName": "Tempdb data files initial size", + "description": "The size and physical placement of the tempdb database can affect the performance of a system. If the size that's defined for tempdb is too small, part of the system-processing load might be taken up with autogrowing tempdb. Space preallocation prevents tempdb from expanding too often, which affects performance.", + "message": "Preallocate space for all tempdb files by setting the file size to a value large enough to accommodate the typical workload in the environment", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/databases/tempdb-database#optimizing-tempdb-performance-in-sql-server", + "level": "Medium", + "threshold": 8, + "condition": { + "gt": [ + "@size_mb", + "@threshold" + ] + }, + "probes": [ + { + "id": "DatabaseMasterFiles", + "params": { + "dbId": 2, + "type": null + }, + "transform": { + "type": "aggregate", + "map": { + "size": "min" + } + } + } + ], + "locals": { + "size_mb": { + "div": [ + { + "mul": [ + "@size", + 8 + ] + }, + 1024 + ] + } + } + }, { "id": "TempDbSameVolume", "itemType": "definition", @@ -11727,6 +17880,325 @@ "SysConfiguration" ] }, + { + "id": "WaitsForWorker", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Wait for the worker", + "tags": [ + "DefaultRuleset", + "Performance", + "CPU" + ], + "description": "SQL Server Wait Statistics\\Wait for Worker counter indicates average time that each SQL Server session is waiting for a worker thread to become available. If the max worker thread setting is set to default, do not increase it. If you configure a number of worker threads to a value that is greater than the default, it is almost always counterproductive and slows performance because of scheduling and resource overhead. Instead, investigate the queries and batches that are holding the threads for the longest duration and engage in fine tuning those queries/batches. Only increase this setting under very unusual circumstances and when rigorous methodical testing demonstrates that it is useful to do so.", + "message": "Investigate the queries and batches that are holding the threads for the longest duration and engage in fine tuning those queries/batches.Wait for the worker\\Average wait time (ms) (@{wait_for_the_worker}) is greater than @{threshold}", + "helpLink": "https://learn.microsoft.com/sql/database-engine/configure-windows/configure-the-max-worker-threads-server-configuration-option", + "threshold": 500, + "condition": { + "le": [ + "@wait_for_the_worker", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "wait_for_the_worker": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WaitsLogWrite", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High transaction log disk response time", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "A high number of waits on Log Writes has been detected. Before any modification to a table can take place, SQL Server must write a record to the Transaction log. Any waits that occur during writes to the Transaction log will result in performance degradation. Evaluate disk performance to identify disk bottlenecks then correlate with SQL Server transactions and tune them.", + "message": "Improve the disk response time for the drives where the Transaction log resides, especially for write operations, log write waits\\Average wait time (ms) (@{log_write_waits}) is greater than @{threshold}", + "helpLink": "https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-sql-io-performance#writelog", + "threshold": 500, + "condition": { + "le": [ + "@log_write_waits", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "log_write_waits": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WaitsNetworkIO", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Network IO", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "Waits on the network I/O are frequently caused by clients not completely processing all data returned by a query or network saturation. Unprocessed results will sit in the output buffer and the SPID will show a wait type for the network I/O until all the results have been received by the client. This introduces the risk of performance degradation. Identify the queries that are waiting on the network I/O and ensure that clients are processing all the results of the query. If you have any network saturation between the server and the application, work to reduce that saturation increasing the number or speed of switches and network cards that are saturated", + "message": "Investigate the cause of high Network I/O Waits and resolve the issues that you find, network IO waits\\Average wait time (ms) (@{network_io_waits}) is greater than @{threshold}", + "helpLink": "https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-query-async-network-io", + "threshold": 500, + "condition": { + "le": [ + "@network_io_waits", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "network_io_waits": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WaitsNonPageLatch", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High non-Page latch waits", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "The SQL Server Wait Statistics\\Non-Page Latch Waits counter indicates the average time that each SQL Server session is waiting on non-page latches. Latches are used to synchronize access to cached data pages and other in-memory objects. Typically, latches are only held briefly, and latch wait times should be correspondingly small. A high number for this counter means that many processes are waiting for latch classes that are not related to buffers which, depending on the latch class, could affect your workload.", + "message": "Non-Page latch waits (@{non_page_latch_waits}) is greater than @{threshold}, take snapshots from sys.dm_os_latch_stats to identify the specific latch class, the identify the queries that are waiting on Non-Page latch and tune them", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention", + "threshold": 500, + "condition": { + "le": [ + "@non_page_latch_waits", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "non_page_latch_waits": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WaitsPageIOLatch", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Page IO latch waits", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "The IO latches are a subset of BUF buffer latches that are used when the buffer and associated data page or the index page is in the middle of an I/O operation. PAGEIOLATCH wait types are used for disk-to-memory transfers and a significant wait time for these wait types suggests disk I/O subsystem issues.", + "message": "Review the disk performance counters including Physical Disk: Disk Sec/Read and Disk Sec/Write and resolve the cause of the high SQL Server Page IO latch wait times (@{page_io_latch_waits} ms), and SQL Server Buffer Manager: Page Life Expectancy to investigate whether there are any disk subsystem issues, review index straegy and query plan for TOP queries with high number of logical reads", + "helpLink": "https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-sql-io-performance", + "threshold": 500, + "condition": { + "le": [ + "@page_io_latch_waits", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "page_io_latch_waits": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WaitsPageLatch", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Page Latch waits", + "tags": [ + "DefaultRuleset", + "Performance" + ], + "description": "The SQL Server Wait Statistics\\Page Latch Waits counter indicates the average time that each SQL Server session is waiting for page latches, not including IO latches. Page Latch Waits can cause a bottleneck in your system and a corresponding adverse effect on performance.", + "message": "Review latch contention, average page latch wait time is @{page_latch_waits} ms", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/diagnose-resolve-latch-contention", + "threshold": 500, + "condition": { + "le": [ + "@page_latch_waits", + "@threshold" + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "transform": { + "type": "performance", + "counters": { + "page_latch_waits": { + "type": "average", + "instance": "Average wait time (ms)" + } + } + } + } + ] + }, + { + "id": "WorkfilesPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Workfiles Created per second", + "tags": [ + "DefaultRuleset", + "Performance", + "Memory" + ], + "description": "Workfiles are created by hash operations, and used to store temporary results for hash joins and hash aggregations. SQL Server creates a work file in tempdb when the amount of data being processed is too big to fit into the available memory used for hash operations, and generates a hash warning as a result. Determine the queries that are generating hash warnings using Extended Events.To eliminate or reduce the frequency of hash recursion and bailouts, do one of the following: Make sure that statistics exist on the columns that are being joined or grouped. If statistics exist on the columns, make sure that these are updated. Tune the query to use a different type of join, namely by adding appropriate indexes. Increase available memory on the computer. Hash recursion or bailout occurs when there is not enough memory to process queries in place and they need to spill to disk. Creating or updating the statistics on the column involved in the join is the most effective way to reduce the number of hash recursion or bailouts that occur, namely when appropriate indexes are already in place.", + "message": "Review query performance to reduce Workfiles Created per sec (@{workfiles_created_sec:0.##})", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/event-classes/hash-warning-event-class", + "threshold": 0.2, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@workfiles_created_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "br", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "workfiles_created_sec": "rate" + } + } + } + ] + }, { "id": "WorkingSetSize", "itemType": "definition", @@ -11754,6 +18226,161 @@ "probes": [ "SysConfiguration" ] + }, + { + "id": "WorktablesFromCache", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "Low Worktables from Cache Ratio", + "tags": [ + "DefaultRuleset", + "Performance", + "Memory" + ], + "description": "The Worktables From Cache Ratio counter records the percentage of worktables that were immediately available from the worktable cache. When a query execution plan is cached, the worktables needed by the plan are not dropped across multiple executions of the plan but only truncated. Because the worktable is cached, the next execution of the query is faster. When the system is low on memory, the execution plan may be removed from the cache and the associated worktables dropped as well.", + "message": "Review application memory requirements, Worktables from Cache Ratio is (@{worktables_from_cache_ratio:P0})", + "helpLink": "https://learn.microsoft.com/troubleshoot/sql/performance/troubleshoot-memory-issues", + "threshold": 0.9, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@worktables_created_sec", + { + "or": [ + { + "mul": [ + "@batch_request_sec", + 0.2 + ] + }, + { + "ge": [ + "@worktables_from_cache_ratio", + "@threshold" + ] + } + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "br", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "worktables_created_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfC", + "transform": { + "type": "performance", + "counters": { + "worktables_from_cache_ratio": { + "type": "ratio", + "base": "worktables_from_cache_base" + } + } + } + } + ] + }, + { + "id": "WorktablesPerSec", + "itemType": "definition", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "displayName": "High Worktables Created per second", + "tags": [ + "DefaultRuleset", + "Performance", + "Memory" + ], + "description": "Worktables are internal tables that are used to hold intermediate results. Worktables are generated for certain GROUP BY, ORDER BY, or UNION queries. For example, if an ORDER BY clause references columns that are not covered by any indexes, the relational engine may need to generate a worktable to sort the result set into the order requested. Worktables are also sometimes used as spools that temporarily hold the result of executing a part of a query plan. Worktables are built in tempdb and are dropped automatically when they are no longer needed.", + "message": "Review table and index strategy, and ensure index and statistics maintenance plans are in place, Worktables Created/sec (@{worktables_created_sec:0.##}) per Batch requests/sec (@{batch_request_sec:0.##}) is greater than @{threshold:P0}", + "helpLink": "https://learn.microsoft.com/sql/relational-databases/performance-monitor/sql-server-access-methods-object", + "threshold": 0.2, + "condition": { + "or": [ + { + "le": [ + "@batch_request_sec", + 100 + ] + }, + { + "le": [ + "@worktables_created_sec", + { + "mul": [ + "@batch_request_sec", + "@threshold" + ] + } + ] + } + ] + }, + "probes": [ + { + "id": "BasicPerformance", + "alias": "br", + "transform": { + "type": "performance", + "counters": { + "batch_request_sec": "rate" + } + } + }, + { + "id": "BasicPerformance", + "alias": "perfB", + "transform": { + "type": "performance", + "counters": { + "worktables_created_sec": "rate" + } + } + } + ] } ], "probes": { @@ -11779,7 +18406,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -11797,7 +18423,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -11815,7 +18440,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -11828,7 +18452,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -11841,7 +18464,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -11927,7 +18549,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -11962,7 +18583,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12013,7 +18633,6 @@ ], "SQLServerVersion": [ { - "type": "SQL", "type": "CLR", "name": "SQLServerVersion", "implementation": { @@ -12060,7 +18679,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12077,7 +18695,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12127,7 +18744,6 @@ { "type": "SQL", "target": { - "type": "Server", "version": [ "[11.0.7001,12.0)", "[12.0.6024,13.0)", @@ -12146,7 +18762,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12226,7 +18841,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12243,7 +18857,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12260,7 +18873,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, @@ -12285,7 +18897,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12457,7 +19068,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12475,12 +19085,12 @@ }, "implementation": { "query": [ - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('disk init',NULL,9),('disk resize',NULL,9),('for load',NULL,9),('dbcc dbrepair',NULL,9),('dbcc newalloc',NULL,9),('dbcc pintable',NULL,9),('dbcc unpintable',NULL,9),('dbcc rowlock',NULL,9),('dbcc textall',NULL,9),('dbcc textalloc',NULL,9),('*=',NULL,9),('=*',NULL,9),('setuser',9,NULL),('sp_helpdevice',9,NULL),('sp_addtype',9,NULL),('sp_attach_db',9,NULL),('sp_attach_single_file_db',9,NULL),('sp_bindefault',9,NULL),('sp_unbindefault',9,NULL),('sp_bindrule',9,NULL),('sp_unbindrule',9,NULL),('create default',9,NULL),('drop default',9,NULL),('create rule',9,NULL),('drop rule',9,NULL),('sp_renamedb',9,NULL),('sp_resetstatus',9,NULL),('dbcc dbreindex',9,NULL),('dbcc indexdefrag',9,NULL),('dbcc showcontig',9,NULL),('sp_addextendedproc',9,NULL),('sp_dropextendedproc',9,NULL),('sp_helpextendedproc',9,NULL),('xp_loginconfig',1,NULL),('sp_fulltext_catalog',9,NULL),('sp_fulltext_table',9,NULL),('sp_fulltext_column',9,NULL),('sp_fulltext_database',9,NULL),('sp_help_fulltext_tables',9,NULL),('sp_help_fulltext_columns',9,NULL),('sp_help_fulltext_catalogs',9,NULL),('sp_help_fulltext_tables_cursor',9,NULL),('sp_help_fulltext_columns_cursor',9,NULL) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END", - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sp_help_fulltext_catalogs_cursor',9,NULL),('fn_get_sql',9,NULL),('sp_indexoption',9,NULL),('sp_lock',9,NULL),('indexkey_property',9,NULL),('file_id',9,NULL),('sp_certify_removable',9,NULL),('sp_create_removable',9,NULL),('sp_dbremove',9,NULL),('sp_addapprole',9,NULL),('sp_dropapprole',9,NULL),('sp_addlogin',9,NULL),('sp_droplogin',9,NULL),('sp_adduser',9,NULL),('sp_dropuser',9,NULL),('sp_grantdbaccess',9,NULL),('sp_revokedbaccess',9,NULL),('sp_addrole',9,NULL),('sp_droprole',9,NULL),('sp_approlepassword',9,NULL),('sp_password',9,NULL),('sp_changeobjectowner',9,NULL),('sp_defaultdb',9,NULL),('sp_defaultlanguage',9,NULL),('sp_denylogin',9,NULL),('sp_grantlogin',9,NULL),('sp_revokelogin',9,NULL),('user_id',9,NULL),('sp_srvrolepermission',9,NULL),('sp_dbfixedrolepermission',9,NULL),('text',9,NULL),('ntext',9,NULL),('image',9,NULL),('textptr',9,NULL),('textvalid',9,NULL),('sp_addalias',9,10),('no_log',9,10),('truncate_only',9,10),('backup transaction',9,10),('dbcc concurrencyviolation',9,10),('sp_addgroup',9,10),('sp_changegroup',9,10),('sp_dropgroup',9,10),('sp_helpgroup',9,10),('sp_makewebtask',NULL,10),('sp_dropwebtask',NULL,10),('sp_runwebtask',NULL,10),('sp_enumcodepages',NULL,10),('dump',9,10),('load',9,10),('sp_articlesynctranprocs',NULL,10),('sp_diskdefault',NULL,10),('sp_eventlog',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END", - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sp_getmbcscharlen',NULL,10),('sp_helplog',NULL,10),('sp_helpsql',NULL,10),('sp_ismbcsleadbyte',NULL,10),('sp_lock2',NULL,10),('sp_msget_current_activity',NULL,10),('sp_msset_current_activity',NULL,10),('sp_msobjessearch',NULL,10),('xp_enum_activescriptengines',NULL,10),('xp_eventlog',NULL,10),('xp_getadmingroupname',NULL,10),('xp_getfiledetails',NULL,10),('xp_getlocalsystemaccountname',NULL,10),('xp_isntadmin',NULL,10),('xp_mslocalsystem',NULL,10),('xp_msnt2000',NULL,10),('xp_msplatform',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END", - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('xp_setsecurity',NULL,10),('xp_varbintohexstr',NULL,10),('spt_datatype_info',NULL,10),('spt_datatype_info_ext',NULL,10),('spt_provider_types',NULL,10),('spt_server_info',NULL,10),('spt_values',NULL,10),('sysfulltextnotify ',NULL,10),('syslocks',NULL,10),('sysproperties',NULL,10),('sysprotects_aux',NULL,10),('sysprotects_view',NULL,10),('sysremote_catalogs',NULL,10),('sysremote_column_privileges',NULL,10),('sysremote_columns',NULL,10),('sysremote_foreign_keys',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END", - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sysremote_indexes',NULL,10),('sysremote_primary_keys',NULL,10),('sysremote_provider_types',NULL,10),('sysremote_schemata',NULL,10),('sysremote_statistics',NULL,10),('sysremote_table_privileges',NULL,10),('sysremote_tables',NULL,10),('sysremote_views',NULL,10),('syssegments',NULL,10),('sysxlogins',NULL,10),('sp_droptype',10,NULL),('@@remserver',10,NULL),('remote_proc_transactions',10,NULL),('sp_addumpdevice',10,NULL),('xp_grantlogin',10,NULL),('xp_revokelogin',10,NULL),('grant all',10,NULL),('deny all',10,NULL),('revoke all',10,NULL),('fn_virtualservernodes',10,NULL),('fn_servershareddrives',10,NULL),('writetext',10,NULL),('updatetext',10,NULL),('readtext',10,NULL),('torn_page_detection',10,NULL),('set rowcount',10,NULL),('dbo_only',9,11 ) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END", - "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('mediapassword',9,11 ),('password',9,11 ),('with append',10,11),('sp_dboption',9,11),('databaseproperty',9,11),('fastfirstrow',10,11),('sp_addserver',10,11 ),('sp_dropalias',9,11),('disable_def_cnst_chk',10,11),('sp_activedirectory_obj',NULL,11),('sp_activedirectory_scp',NULL,11),('sp_activedirectory_start',NULL,11),('sys.database_principal_aliases',NULL,11),('compute',10,11),('compute by',10,11),('sp_change_users_login',11,NULL),('sp_depends',11,NULL),('sp_getbindtoken',11,NULL),('sp_bindsession',11,NULL),('fmtonly',11,NULL),('raiserror',11,NULL),('sp_db_increased_partitions',11,NULL),('databasepropertyex(''isfulltextenabled'')',11,NULL),('sp_dbcmptlevel',11,NULL),('set ansi_nulls off',11,NULL),('set ansi_padding off',11,NULL),('set concat_null_yields_null off',11,NULL),('set offsets',11,NULL),('sys.numbered_procedures',12,NULL),('sys.numbered_procedure_parameters',12,NULL),('sys.sql_dependencies',12,NULL),('sp_db_vardecimal_storage_format',12,NULL),('sp_estimated_rowsize_reduction_for_vardecimal',12,NULL),('sp_trace_create',12,NULL),('sp_trace_setevent',12,NULL),('sp_trace_setstatus',12,NULL),('fn_trace_geteventinfo',12,NULL),('fn_trace_getfilterinfo',12,NULL),('fn_trace_gettable',12,NULL),('sys.traces',12,NULL),('sys.trace_events',12,NULL),('sys.trace_event_bindings',12,NULL),('sys.trace_categories',12,NULL),('sys.trace_columns',12,NULL),('sys.trace_subclass_values',12,NULL),('sp_addremotelogin',10,14),('sp_dropremotelogin',10,14),('sp_helpremotelogin',10,14),('sp_remoteoption',10,14) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] IN ('TSQL','PowerShell'); END" + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('disk init',NULL,9),('disk resize',NULL,9),('for load',NULL,9),('dbcc dbrepair',NULL,9),('dbcc newalloc',NULL,9),('dbcc pintable',NULL,9),('dbcc unpintable',NULL,9),('dbcc rowlock',NULL,9),('dbcc textall',NULL,9),('dbcc textalloc',NULL,9),('*=',NULL,9),('=*',NULL,9),('setuser',9,NULL),('sp_helpdevice',9,NULL),('sp_addtype',9,NULL),('sp_attach_db',9,NULL),('sp_attach_single_file_db',9,NULL),('sp_bindefault',9,NULL),('sp_unbindefault',9,NULL),('sp_bindrule',9,NULL),('sp_unbindrule',9,NULL),('create default',9,NULL),('drop default',9,NULL),('create rule',9,NULL),('drop rule',9,NULL),('sp_renamedb',9,NULL),('sp_resetstatus',9,NULL),('dbcc dbreindex',9,NULL),('dbcc indexdefrag',9,NULL),('dbcc showcontig',9,NULL),('sp_addextendedproc',9,NULL),('sp_dropextendedproc',9,NULL),('sp_helpextendedproc',9,NULL),('xp_loginconfig',1,NULL),('sp_fulltext_catalog',9,NULL),('sp_fulltext_table',9,NULL),('sp_fulltext_column',9,NULL),('sp_fulltext_database',9,NULL),('sp_help_fulltext_tables',9,NULL),('sp_help_fulltext_columns',9,NULL),('sp_help_fulltext_catalogs',9,NULL),('sp_help_fulltext_tables_cursor',9,NULL),('sp_help_fulltext_columns_cursor',9,NULL) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END", + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sp_help_fulltext_catalogs_cursor',9,NULL),('fn_get_sql',9,NULL),('sp_indexoption',9,NULL),('sp_lock',9,NULL),('indexkey_property',9,NULL),('file_id',9,NULL),('sp_certify_removable',9,NULL),('sp_create_removable',9,NULL),('sp_dbremove',9,NULL),('sp_addapprole',9,NULL),('sp_dropapprole',9,NULL),('sp_addlogin',9,NULL),('sp_droplogin',9,NULL),('sp_adduser',9,NULL),('sp_dropuser',9,NULL),('sp_grantdbaccess',9,NULL),('sp_revokedbaccess',9,NULL),('sp_addrole',9,NULL),('sp_droprole',9,NULL),('sp_approlepassword',9,NULL),('sp_password',9,NULL),('sp_changeobjectowner',9,NULL),('sp_defaultdb',9,NULL),('sp_defaultlanguage',9,NULL),('sp_denylogin',9,NULL),('sp_grantlogin',9,NULL),('sp_revokelogin',9,NULL),('user_id',9,NULL),('sp_srvrolepermission',9,NULL),('sp_dbfixedrolepermission',9,NULL),('text',9,NULL),('ntext',9,NULL),('image',9,NULL),('textptr',9,NULL),('textvalid',9,NULL),('sp_addalias',9,10),('no_log',9,10),('truncate_only',9,10),('backup transaction',9,10),('dbcc concurrencyviolation',9,10),('sp_addgroup',9,10),('sp_changegroup',9,10),('sp_dropgroup',9,10),('sp_helpgroup',9,10),('sp_makewebtask',NULL,10),('sp_dropwebtask',NULL,10),('sp_runwebtask',NULL,10),('sp_enumcodepages',NULL,10),('dump',9,10),('load',9,10),('sp_articlesynctranprocs',NULL,10),('sp_diskdefault',NULL,10),('sp_eventlog',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END", + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sp_getmbcscharlen',NULL,10),('sp_helplog',NULL,10),('sp_helpsql',NULL,10),('sp_ismbcsleadbyte',NULL,10),('sp_lock2',NULL,10),('sp_msget_current_activity',NULL,10),('sp_msset_current_activity',NULL,10),('sp_msobjessearch',NULL,10),('xp_enum_activescriptengines',NULL,10),('xp_eventlog',NULL,10),('xp_getadmingroupname',NULL,10),('xp_getfiledetails',NULL,10),('xp_getlocalsystemaccountname',NULL,10),('xp_isntadmin',NULL,10),('xp_mslocalsystem',NULL,10),('xp_msnt2000',NULL,10),('xp_msplatform',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END", + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('xp_setsecurity',NULL,10),('xp_varbintohexstr',NULL,10),('spt_datatype_info',NULL,10),('spt_datatype_info_ext',NULL,10),('spt_provider_types',NULL,10),('spt_server_info',NULL,10),('spt_values',NULL,10),('sysfulltextnotify ',NULL,10),('syslocks',NULL,10),('sysproperties',NULL,10),('sysprotects_aux',NULL,10),('sysprotects_view',NULL,10),('sysremote_catalogs',NULL,10),('sysremote_column_privileges',NULL,10),('sysremote_columns',NULL,10),('sysremote_foreign_keys',NULL,10) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END", + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('sysremote_indexes',NULL,10),('sysremote_primary_keys',NULL,10),('sysremote_provider_types',NULL,10),('sysremote_schemata',NULL,10),('sysremote_statistics',NULL,10),('sysremote_table_privileges',NULL,10),('sysremote_tables',NULL,10),('sysremote_views',NULL,10),('syssegments',NULL,10),('sysxlogins',NULL,10),('sp_droptype',10,NULL),('@@remserver',10,NULL),('remote_proc_transactions',10,NULL),('sp_addumpdevice',10,NULL),('xp_grantlogin',10,NULL),('xp_revokelogin',10,NULL),('grant all',10,NULL),('deny all',10,NULL),('revoke all',10,NULL),('fn_virtualservernodes',10,NULL),('fn_servershareddrives',10,NULL),('writetext',10,NULL),('updatetext',10,NULL),('readtext',10,NULL),('torn_page_detection',10,NULL),('set rowcount',10,NULL),('dbo_only',9,11 ) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END", + "USE [msdb]; IF (SELECT COUNT(instance_name) FROM sys.dm_os_performance_counters WHERE [object_name] LIKE '%Deprecated Features%' AND cntr_value>0)>0 BEGIN DECLARE @sqlmajorver INT; SELECT @sqlmajorver=CONVERT(int,(@@microsoftversion / 0x1000000) & 0xff); DECLARE @tblKeywords as TABLE (KeywordID int IDENTITY(1,1) PRIMARY KEY, Keyword VARCHAR(64), DeprecatedIn tinyint, DiscontinuedIn tinyint) INSERT INTO @tblKeywords VALUES ('mediapassword',9,11 ),('password',9,11 ),('with append',10,11),('sp_dboption',9,11),('databaseproperty',9,11),('fastfirstrow',10,11),('sp_addserver',10,11 ),('sp_dropalias',9,11),('disable_def_cnst_chk',10,11),('sp_activedirectory_obj',NULL,11),('sp_activedirectory_scp',NULL,11),('sp_activedirectory_start',NULL,11),('sys.database_principal_aliases',NULL,11),('compute',10,11),('compute by',10,11),('sp_change_users_login',11,NULL),('sp_depends',11,NULL),('sp_getbindtoken',11,NULL),('sp_bindsession',11,NULL),('fmtonly',11,NULL),('raiserror',11,NULL),('sp_db_increased_partitions',11,NULL),('databasepropertyex(''isfulltextenabled'')',11,NULL),('sp_dbcmptlevel',11,NULL),('set ansi_nulls off',11,NULL),('set ansi_padding off',11,NULL),('set concat_null_yields_null off',11,NULL),('set offsets',11,NULL),('sys.numbered_procedures',12,NULL),('sys.numbered_procedure_parameters',12,NULL),('sys.sql_dependencies',12,NULL),('sp_db_vardecimal_storage_format',12,NULL),('sp_estimated_rowsize_reduction_for_vardecimal',12,NULL),('sp_trace_create',12,NULL),('sp_trace_setevent',12,NULL),('sp_trace_setstatus',12,NULL),('fn_trace_geteventinfo',12,NULL),('fn_trace_getfilterinfo',12,NULL),('fn_trace_gettable',12,NULL),('sys.traces',12,NULL),('sys.trace_events',12,NULL),('sys.trace_event_bindings',12,NULL),('sys.trace_categories',12,NULL),('sys.trace_columns',12,NULL),('sys.trace_subclass_values',12,NULL),('sp_addremotelogin',10,14),('sp_dropremotelogin',10,14),('sp_helpremotelogin',10,14),('sp_remoteoption',10,14) DELETE FROM @tblKeywords WHERE DeprecatedIn>@sqlmajorver OR DiscontinuedIn>@sqlmajorver SELECT 'Job: '+sj.[name]+' Step: '+sjs.step_name AS ObjectName,Keyword FROM msdb.dbo.sysjobsteps sjs (NOLOCK) INNER JOIN msdb.dbo.sysjobs sj (NOLOCK) ON sjs.job_id=sj.job_id CROSS JOIN @tblKeywords tk WHERE PATINDEX('%'+tk.Keyword+'%',LOWER(sjs.[command]) COLLATE DATABASE_DEFAULT)>1 AND sjs.[subsystem] = 'TSQL'; END" ], "transform": { "type": "aggregate", @@ -12496,7 +19106,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": "Windows", "version": "[11.0,)" }, @@ -12601,7 +19210,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12633,7 +19241,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12757,11 +19364,11 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" ], + "engineEdition": "SqlServer, ManagedInstance", "version": "[11.0,)" }, "implementation": { @@ -12865,7 +19472,6 @@ { "type": "WMI", "target": { - "type": "Server", "platform": "Windows", "engineEdition": "SqlServer", "version": "[11.0,)" @@ -12882,7 +19488,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -12891,12 +19496,12 @@ "version": "[11.0,)" }, "requires": { - "object permission on xp_enumerrorlogs": [ + "object permission on sys.xp_enumerrorlogs": [ "EXECUTE" ] }, "implementation": { - "query": "DECLARE @errorlogs TABLE ( id INT ,[date] NVARCHAR(256) ,size BIGINT ) INSERT INTO @errorlogs EXEC [master].sys.xp_enumerrorlogs SELECT * FROM @errorlogs" + "query": "DECLARE @errorlogs TABLE ( id INT ,[date] NVARCHAR(256) ,size BIGINT ) INSERT INTO @errorlogs EXEC [master].sys.xp_enumerrorlogs SELECT * ,DATEDIFF(dd, [date], GETDATE()) AS age_days FROM @errorlogs" } } ], @@ -12904,7 +19509,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -12921,11 +19525,11 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" ], + "engineEdition": "SqlServer", "version": "[11.0,)" }, "implementation": { @@ -12937,7 +19541,6 @@ { "type": "WMI", "target": { - "type": "Server", "platform": "Windows", "engineEdition": "SqlServer", "version": "[11.0,)" @@ -12951,7 +19554,6 @@ { "type": "WMI", "target": { - "type": "Server", "platform": "Windows", "engineEdition": "SqlServer", "version": "[11.0,)" @@ -12965,7 +19567,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -12983,7 +19584,6 @@ { "type": "Registry", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13003,7 +19603,6 @@ { "type": "Registry", "target": { - "type": "Server", "platform": "Windows", "engineEdition": "SqlServer", "version": "[11.0,)" @@ -13044,7 +19643,6 @@ { "type": "Registry", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13065,7 +19663,6 @@ { "type": "Registry", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13085,7 +19682,6 @@ { "type": "Registry", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13111,7 +19707,6 @@ { "type": "PowerShell", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13125,7 +19720,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13168,13 +19762,16 @@ "priority boost": "priority_boost", "query wait (s)": "query_wait", "recovery interval (min)": "recovery_interval", + "remote access": "remote_access", "remote admin connections": "remote_admin_connections", + "remote login timeout (s)": "remote_login_timeout", "remote query timeout (s)": "remote_query_timeout", "scan for startup procs": "startup_stored_procedures", "xp_cmdshell": "xp_cmdshell", "fill factor (%)": "fill_factor", "disallow results from triggers": "disallow_results_from_triggers", "nested triggers": "nested_triggers", + "server trigger recursion": "server_trigger_recursion", "open objects": "open_objects", "user connections": "user_connections", "max full-text crawl range": "max_full_text_crawl_range", @@ -13205,6 +19802,7 @@ "contained database authentication": "contained_database_authentication", "remote proc trans": "remote_proc_trans", "c2 audit mode": "c2_audit_mode", + "default language": "default_language", "default full-text language": "default_full_text_language", "two digit year cutoff": "two_digit_year_cutoff" } @@ -13223,7 +19821,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13241,7 +19838,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Linux", "version": "[11.0,)" @@ -13261,7 +19857,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13278,7 +19873,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13297,7 +19891,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13314,7 +19907,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": "Windows", "engineEdition": "SqlServer", "version": "[11.0,)" @@ -13328,7 +19920,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": [ "Windows", @@ -13345,7 +19936,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13359,13 +19949,12 @@ ] }, "implementation": { - "query": "SELECT ag.group_id AS ag_id, ag.[name] AS ag_name, ar.replica_id, ar.replica_server_name AS ag_replica_server, ar_state.is_local AS is_ag_replica_local, ar.availability_mode, ar.availability_mode_desc, ar.failover_mode, ar.failover_mode_desc, ar_state.[role] AS ag_replica_role, ar_state.role_desc AS ag_replica_role_desc, ar_state.operational_state AS ag_replica_operational_state, ISNULL(ar_state.operational_state_desc, 'UNKNOWN') AS ag_replica_operational_state_desc, ar_state.connected_state AS ag_replica_connected_state, ar_state.synchronization_health AS ag_replica_synchronization_health, ar.secondary_role_allow_connections, ar.secondary_role_allow_connections_desc, avg_state.primary_recovery_health, avg_state.primary_recovery_health_desc, avg_state.synchronization_health, avg_state.synchronization_health_desc, ar.backup_priority, ag.automated_backup_preference, ag.automated_backup_preference_desc, ag.failure_condition_level, ag.health_check_timeout, ar.session_timeout, ar.endpoint_url, CASE WHEN loc_r.replica_id IS NOT NULL THEN 1 ELSE 0 END AS is_on_primary_replica, 0 AS is_distributed FROM sys.availability_groups AS ag WITH (NOLOCK) INNER JOIN sys.availability_replicas AS ar WITH (NOLOCK) ON ag.group_id = ar.group_id INNER JOIN sys.dm_hadr_availability_replica_states AS ar_state WITH (NOLOCK) ON ar.replica_id = ar_state.replica_id INNER JOIN sys.dm_hadr_availability_group_states AS avg_state WITH (NOLOCK) ON avg_state.group_id = ag.group_id LEFT JOIN sys.dm_hadr_availability_replica_states AS loc_r WITH (NOLOCK) ON loc_r.is_local = 1 AND loc_r.[role] = 1 AND loc_r.group_id = ag.group_id" + "query": "SELECT ag.group_id AS ag_id, ag.[name] AS ag_name, ar.replica_id, ar.replica_server_name AS ag_replica_server, ar_state.is_local AS is_ag_replica_local, ar.availability_mode, ar.availability_mode_desc, ar.failover_mode, ar.failover_mode_desc, ar_state.[role] AS ag_replica_role, ar_state.role_desc AS ag_replica_role_desc, ar_state.operational_state AS ag_replica_operational_state, ISNULL(ar_state.operational_state_desc, 'UNKNOWN') AS ag_replica_operational_state_desc, ar_state.connected_state AS ag_replica_connected_state, ar_state.synchronization_health AS ag_replica_synchronization_health, ar.secondary_role_allow_connections, ar.secondary_role_allow_connections_desc, avg_state.primary_recovery_health, avg_state.primary_recovery_health_desc, avg_state.synchronization_health, avg_state.synchronization_health_desc, ar.backup_priority, ag.automated_backup_preference, ag.automated_backup_preference_desc, ag.failure_condition_level, ag.health_check_timeout, ar.session_timeout, ar.endpoint_url, CASE WHEN loc_r.replica_id IS NOT NULL THEN 1 ELSE 0 END AS is_on_primary_replica, CAST(0 AS BIT) AS is_distributed, ar_state.recovery_health AS ag_replica_recovery_health FROM sys.availability_groups AS ag WITH (NOLOCK) INNER JOIN sys.availability_replicas AS ar WITH (NOLOCK) ON ag.group_id = ar.group_id INNER JOIN sys.dm_hadr_availability_replica_states AS ar_state WITH (NOLOCK) ON ar.replica_id = ar_state.replica_id INNER JOIN sys.dm_hadr_availability_group_states AS avg_state WITH (NOLOCK) ON avg_state.group_id = ag.group_id LEFT JOIN sys.dm_hadr_availability_replica_states AS loc_r WITH (NOLOCK) ON loc_r.is_local = 1 AND loc_r.[role] = 1 AND loc_r.group_id = ag.group_id" } }, { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13379,7 +19968,7 @@ ] }, "implementation": { - "query": "SELECT ag.group_id AS ag_id, ag.[name] AS ag_name, ar.replica_id, ar.replica_server_name AS ag_replica_server, ar_state.is_local AS is_ag_replica_local, ar.availability_mode, ar.availability_mode_desc, ar.failover_mode, ar.failover_mode_desc, ar_state.[role] AS ag_replica_role, ar_state.role_desc AS ag_replica_role_desc, ar_state.operational_state AS ag_replica_operational_state, ISNULL(ar_state.operational_state_desc, 'UNKNOWN') AS ag_replica_operational_state_desc, ar_state.connected_state AS ag_replica_connected_state, ar_state.synchronization_health AS ag_replica_synchronization_health, ar.secondary_role_allow_connections, ar.secondary_role_allow_connections_desc, avg_state.primary_recovery_health, avg_state.primary_recovery_health_desc, avg_state.synchronization_health, avg_state.synchronization_health_desc, ar.backup_priority, ag.automated_backup_preference, ag.automated_backup_preference_desc, ag.failure_condition_level, ag.health_check_timeout, ar.session_timeout, ar.endpoint_url, CASE WHEN loc_r.replica_id IS NOT NULL THEN 1 ELSE 0 END AS is_on_primary_replica, ag.is_distributed FROM sys.availability_groups AS ag WITH (NOLOCK) INNER JOIN sys.availability_replicas AS ar WITH (NOLOCK) ON ag.group_id = ar.group_id INNER JOIN sys.dm_hadr_availability_replica_states AS ar_state WITH (NOLOCK) ON ar.replica_id = ar_state.replica_id INNER JOIN sys.dm_hadr_availability_group_states AS avg_state WITH (NOLOCK) ON avg_state.group_id = ag.group_id LEFT JOIN sys.dm_hadr_availability_replica_states AS loc_r WITH (NOLOCK) ON loc_r.is_local = 1 AND loc_r.[role] = 1 AND loc_r.group_id = ag.group_id" + "query": "SELECT ag.group_id AS ag_id, ag.[name] AS ag_name, ar.replica_id, ar.replica_server_name AS ag_replica_server, ar_state.is_local AS is_ag_replica_local, ar.availability_mode, ar.availability_mode_desc, ar.failover_mode, ar.failover_mode_desc, ar_state.[role] AS ag_replica_role, ar_state.role_desc AS ag_replica_role_desc, ar_state.operational_state AS ag_replica_operational_state, ISNULL(ar_state.operational_state_desc, 'UNKNOWN') AS ag_replica_operational_state_desc, ar_state.connected_state AS ag_replica_connected_state, ar_state.synchronization_health AS ag_replica_synchronization_health, ar.secondary_role_allow_connections, ar.secondary_role_allow_connections_desc, avg_state.primary_recovery_health, avg_state.primary_recovery_health_desc, avg_state.synchronization_health, avg_state.synchronization_health_desc, ar.backup_priority, ag.automated_backup_preference, ag.automated_backup_preference_desc, ag.failure_condition_level, ag.health_check_timeout, ar.session_timeout, ar.endpoint_url, CASE WHEN loc_r.replica_id IS NOT NULL THEN 1 ELSE 0 END AS is_on_primary_replica, ag.is_distributed, ar_state.recovery_health AS ag_replica_recovery_health FROM sys.availability_groups AS ag WITH (NOLOCK) INNER JOIN sys.availability_replicas AS ar WITH (NOLOCK) ON ag.group_id = ar.group_id INNER JOIN sys.dm_hadr_availability_replica_states AS ar_state WITH (NOLOCK) ON ar.replica_id = ar_state.replica_id INNER JOIN sys.dm_hadr_availability_group_states AS avg_state WITH (NOLOCK) ON avg_state.group_id = ag.group_id LEFT JOIN sys.dm_hadr_availability_replica_states AS loc_r WITH (NOLOCK) ON loc_r.is_local = 1 AND loc_r.[role] = 1 AND loc_r.group_id = ag.group_id" } } ], @@ -13387,7 +19976,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13409,7 +19997,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13431,7 +20018,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13449,9 +20035,54 @@ } } ], - "AzDiskMetadata": [ + "AuditSpecs": [ { "type": "SQL", + "target": { + "type": "Server", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT server_specification_id AS spec_id ,[name] AS spec_name ,audit_guid AS server_audit_guid FROM sys.server_audit_specifications" + } + }, + { + "type": "SQL", + "target": { + "type": "Database", + "platform": "Windows", + "engineEdition": "Enterprise", + "version": "[11.0, 13.0.4001)" + }, + "implementation": { + "useDatabase": true, + "query": "SELECT database_specification_id AS spec_id ,[name] AS spec_name ,audit_guid AS server_audit_guid FROM sys.database_audit_specifications" + } + }, + { + "type": "SQL", + "target": { + "type": "Database", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[13.0.4001,)" + }, + "implementation": { + "useDatabase": true, + "query": "SELECT database_specification_id AS spec_id ,[name] AS spec_name ,audit_guid AS server_audit_guid FROM sys.database_audit_specifications" + } + } + ], + "AzDiskMetadata": [ + { "type": "CLR", "name": "AzDiskMetadata", "target": { @@ -13467,7 +20098,6 @@ ], "AzStorage": [ { - "type": "SQL", "type": "CLR", "name": "AzStorage", "target": { @@ -13485,7 +20115,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13498,11 +20127,126 @@ } } ], + "BasicPerformance": [ + { + "type": "Performance", + "target": { + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "implementation": { + "NumberOfSamples": 2, + "Interval": 15, + "Counters": { + "Access Methods": { + "Forwarded Records/sec": "forwarded_records_sec", + "FreeSpace Scans/sec": "freespace_scans_sec", + "Full Scans/sec": "full_scans_sec", + "Index Searches/sec": "index_searches_sec", + "Page Splits/sec": "page_splits_sec", + "Scan Point Revalidations/sec": "scan_point_revalidations_sec", + "Workfiles Created/sec": "workfiles_created_sec", + "Worktables Created/sec": "worktables_created_sec", + "Worktables From Cache Base": "worktables_from_cache_base", + "Worktables From Cache Ratio": "worktables_from_cache_ratio" + }, + "Buffer Manager": { + "Buffer cache hit ratio": "buffer_cache_hit_ratio", + "Buffer cache hit ratio base": "buffer_cache_hit_ratio_base", + "Lazy writes": "lazy_writes", + "Page life expectancy": "page_life_expectancy", + "Page lookups/sec": "page_lookups_sec" + }, + "Cursor Manager by Type": { + "Cursor Requests/sec": "cursor_requests_sec" + }, + "Database Replica": { + "Log Send Queue": "log_send_queue", + "Mirrored Write Transactions/sec": "mirrored_write_transactions_sec", + "Recovery Queue": "recovery_queue", + "Transaction Delay": "transaction_delay" + }, + "Latches": { + "Total Latch Wait Time (ms)": "total_latch_wait_time_ms", + "Latch Waits/sec": "latch_waits_sec" + }, + "Locks": { + "Lock Wait Time (ms)": "lock_wait_time_ms", + "Number of Deadlocks/sec": "number_of_deadlocks_sec", + "Lock Requests/sec": "lock_requests_sec" + }, + "Memory Manager": { + "Free Memory (KB)": "free_memory_kb", + "Memory Grants Pending": "memory_grants_pending" + }, + "SQL Statistics": { + "Batch Requests/sec": "batch_request_sec", + "SQL Compilations/sec": "sql_compilations_sec", + "SQL Re-Compilations/sec": "sql_recompilations_sec" + }, + "Wait Statistics": { + "Log write waits": "log_write_waits", + "Network IO waits": "network_io_waits", + "Non-Page latch waits": "non_page_latch_waits", + "Page IO latch waits": "page_io_latch_waits", + "Page latch waits": "page_latch_waits", + "Wait for the worker": "wait_for_the_worker" + } + } + } + } + ], + "ComputerSystem": [ + { + "type": "WMI", + "target": { + "platform": "Windows", + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT DomainRole FROM Win32_ComputerSystem" + } + } + ], + "DatabaseBackupsMedia": [ + { + "type": "SQL", + "target": { + "type": "Database", + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT b.[database_name] ,b.[name] AS backup_name ,b.[type] AS backup_type ,b.recovery_model ,m.[name] AS mediaset_name ,f.logical_device_name ,f.physical_device_name ,f.device_type FROM msdb..backupset b INNER JOIN msdb..backupmediaset m ON b.media_set_id = m.media_set_id INNER JOIN msdb..backupmediafamily f ON m.media_set_id = f.media_set_id WHERE b.[type] = ISNULL(NULL, b.[type]) AND b.[database_name] = @TargetName" + } + } + ], + "DatabaseMirroring": [ + { + "type": "SQL", + "target": { + "platform": "Windows", + "engineEdition": "SqlServer", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT db.database_id ,db.[name] AS [database_name] ,mirroring_state ,mirroring_role FROM sys.databases AS db INNER JOIN sys.database_mirroring AS dbm ON dbm.database_id = db.database_id WHERE mirroring_state IS NOT NULL" + } + } + ], "DatabasesAggregates": [ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13545,7 +20289,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13562,7 +20305,6 @@ { "type": "Registry", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13598,7 +20340,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13607,7 +20348,32 @@ "version": "[11.0,)" }, "implementation": { - "query": "SELECT [name] AS [unsaved_option] FROM sys.configurations WITH(NOLOCK) WHERE [value] <> [value_in_use]" + "query": "SELECT [name] AS unsaved_option FROM ( SELECT [name] ,CASE WHEN configuration_id = 1543 AND [value] = 0 AND value_in_use <> 0 THEN CASE WHEN CAST(SERVERPROPERTY('Edition') AS NVARCHAR(128)) LIKE '%(64-bit)' THEN 16 ELSE 8 END WHEN configuration_id = 1544 AND [value] = 0 AND value_in_use <> 0 THEN 2147483647 ELSE [value] END AS configured_value ,value_in_use FROM sys.configurations ) AS i WHERE configured_value <> value_in_use" + } + } + ], + "ErrorLog": [ + { + "type": "SQL", + "target": { + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "requires": { + "object permission on sys.xp_enumerrorlogs": [ + "EXECUTE" + ], + "object permission on sys.xp_readerrorlog": [ + "EXECUTE" + ] + }, + "implementation": { + "timeout": 90, + "query": "DECLARE @filter NVARCHAR(2048) ,@pattern NVARCHAR(2048) SELECT @pattern = REPLACE(LEFT([text], CHARINDEX(fc, [text]) + LEN(fc)), fc, '%') ,@filter = LEFT([text], CHARINDEX('%', [text]) - 1) FROM ( SELECT CASE WHEN CHARINDEX('%d', [text]) > 0 THEN '%d' ELSE '%1!' END AS fc ,[text] FROM sys.messages WHERE message_id = 18052 AND language_id = ( SELECT msglangid FROM sys.syslanguages WHERE [name] = ISNULL(@language, @@LANGUAGE) COLLATE DATABASE_DEFAULT ) ) AS i DECLARE @errorlogs TABLE ( num INT ,[date] DATETIME ,[size] INT ) INSERT INTO @errorlogs EXEC xp_enumerrorlogs DELETE FROM @errorlogs WHERE [size] > @max_log_size_mb * 1048576 OR [date] < DATEADD(day, - @history_days, GETDATE()) DECLARE @content TABLE ( [date] DATETIME ,spid VARCHAR(50) ,[message] NVARCHAR(4000) ) DECLARE @results TABLE ( errorId INT ,[date] DATETIME ) DECLARE @i INT = - 1 WHILE EXISTS ( SELECT 1 FROM @errorlogs WHERE num > @i ) BEGIN SET @i = ( SELECT TOP 1 num FROM @errorlogs WHERE num > @i ORDER BY num ) INSERT INTO @content EXEC sys.xp_readerrorlog @i ,1 ,@filter INSERT INTO @results SELECT LEFT(l, CHARINDEX(RIGHT(@pattern, 1), l) - 1) ,[date] FROM ( SELECT LTRIM(RIGHT(RTRIM([message]), LEN(RTRIM([message])) - LEN(@filter))) AS l ,[date] FROM @content AS c WHERE c.[message] LIKE (@pattern + '%') COLLATE DATABASE_DEFAULT ) AS i DELETE FROM @content END SELECT errorId ,COUNT(errorId) AS error_count ,MAX([date]) AS last_occurrence FROM @results GROUP BY errorId" } } ], @@ -13649,7 +20415,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13684,11 +20449,42 @@ } } ], + "ServerAudits": [ + { + "type": "SQL", + "target": { + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT audit_id ,audit_guid ,[name] AS audit_name FROM sys.server_audits" + } + } + ], + "ServerDatabasesProperties": [ + { + "type": "SQL", + "target": { + "engineEdition": "SqlServer, ManagedInstance", + "platform": [ + "Windows", + "Linux" + ], + "version": "[11.0,)" + }, + "implementation": { + "query": "DECLARE @ColumnStoreTables TABLE(ID INT PRIMARY KEY, DatabaseName NVARCHAR(128), ColumnStoreIndexCount INT) DECLARE @Id INT, @IndexCount INT, @Sql NVARCHAR(255), @MaxId INT INSERT INTO @ColumnStoreTables SELECT ROW_NUMBER() OVER(ORDER BY database_id), [name], 0 FROM sys.databases WHERE HAS_DBACCESS([name]) = 1 SET @Id = 1 SELECT @MaxId = MAX(ID) FROM @ColumnStoreTables WHILE @Id <= @MaxId BEGIN SELECT @Sql = 'USE ' + QUOTENAME(DatabaseName) + ' SELECT @cnt = COUNT(*) FROM sys.indexes WHERE [type] IN (5, 6)' FROM @ColumnStoreTables WHERE ID = @Id BEGIN TRY EXEC sp_executesql @Sql, N'@cnt INT OUTPUT', @IndexCount OUTPUT UPDATE @ColumnStoreTables SET ColumnStoreIndexCount = @IndexCount WHERE ID = @Id END TRY BEGIN CATCH UPDATE @ColumnStoreTables SET ColumnStoreIndexCount = NULL WHERE ID = @Id END CATCH SET @Id = @Id + 1 END SELECT DatabaseName, ColumnStoreIndexCount FROM @ColumnStoreTables WHERE ColumnStoreIndexCount IS NOT NULL" + } + } + ], "ServerProperties": [ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13704,7 +20500,6 @@ { "type": "WMI", "target": { - "type": "Server", "engineEdition": "SqlServer", "platform": "Windows", "version": "[11.0,)" @@ -13736,7 +20531,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13753,7 +20547,6 @@ { "type": "SQL", "target": { - "type": "Server", "platform": [ "Windows", "Linux" @@ -13770,7 +20563,6 @@ { "type": "SQL", "target": { - "type": "Server", "engineEdition": "SqlServer, ManagedInstance", "platform": [ "Windows", @@ -13783,6 +20575,22 @@ } } ], + "SysOpenTranSessions": [ + { + "type": "SQL", + "target": { + "platform": [ + "Windows", + "Linux" + ], + "engineEdition": "SqlServer, ManagedInstance", + "version": "[11.0,)" + }, + "implementation": { + "query": "SELECT session_id ,[status] ,open_transaction_count ,database_id ,cpu_time ,memory_usage FROM sys.dm_exec_sessions WITH (NOLOCK) WHERE is_user_process = ISNULL(@user_session, is_user_process) AND [status] = ISNULL(@status, [status]) AND session_id <> @@spid AND DATEDIFF(MINUTE, ISNULL(last_request_end_time, GETDATE()), GETDATE()) >= @last_request_end_min AND open_transaction_count > 0" + } + } + ], "TablesInformation": [ { "type": "SQL",