SQL SERVER operation and maintenance inspection series eight - performance

foreword

  Doing a good job in daily inspection is an important step in database management and maintenance, and it is necessary to register the date and results of each inspection, and may need to issue an inspection report.

  This series aims to address some common pitfalls:

  • I don't know what to check
  • I don't know how to check easily
  • Too many machines, check up trouble
  • Difficulty in generating reports and inability to visualize results

 

  Performance is one of the important indicators of the quality of the system, and performance problems may be caused by a small point (such as parameter configuration, job configuration, structural design, software and hardware environment, etc.). The previous seven articles have inspected the system from different aspects. This article will introduce the most important item (performance) in the series of inspections.

performance baseline

  There are many indicators of performance inspection, and the situation changes greatly, so you should establish a complete performance evaluation model for your own system. What is a performance evaluation model, that is, when the system enters a stable period, after optimization, the system performance A stable value has been reached, then we can use this stable project as a baseline for post-inspection, functional launch, structural changes and other operational performance comparisons.

  On the [Physical Examination Items] page, we can use a relatively stable historical version of the physical examination item as the performance baseline, which can be renamed as "Performance Baseline" in order to distinguish other items.

  

  

Based on performance baseline comparison

 Overall indicator

  On the [Overview] page, we can view the performance status of the system as a whole, mainly from [Query Statement-Execution Time], [Session-Wait Type], [Check Items], etc., to compare with the baseline. Check whether the indicators in the inspection are significantly different from the baseline indicators.

  Example: During the inspection, the number of slow statements in each time period in [Query Statement - Execution Time] is significantly higher than the baseline, which means that the statements in the system may become slower. The pressure of system indicators such as CPU, memory, and IO increases, indicating that the pressure on your system has increased. The reason for the increase may be due to newly added unoptimized statements or problems with hardware resources.

  Note: The collection time of baseline and inspection should be the same or slightly different. If the difference is large, it may not be descriptive.

   

 

specific indicators

  counter

  • system counter
  • database counter

  

  check sentence

  During inspections, we can mainly focus on:

   

  • Number of slow statements

  

  • execution times top 10
  • duration top 10
  • CPU consumption top 10
  • top 10 reads
  • Write times top 10
  • Affect the number of rows top 10

  

 

 

 System waiting and blocking

  During inspections, we can mainly focus on:

  • The type and number of waits are distributed

  

  • wait time distribution

  

 

  • Waiting times top 10
  • Waiting time top 10
  • CPU time top 10
  • 逻辑读次数 top 10
  • 物理读次数top 10
  • 物理写top 10

  

 

 其他指标

  数据库的性能巡检指标很多,可以根据自己系统的情况选择,具体指标及优化方式请参见:性能诊断系列

 

总结

  前面的一些巡检项及配置项,在管理比较规范的系统下,一般并不会出现什么问题,而性能不同,这是一个受很多因素影响,并且比较容易产生问题的项。同时性能对系统的总要程度是不言而喻的,做好前面的巡检也是性能稳定的保证。

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326442474&siteId=291194637