CN117056182B - 一种SQL Server数据库性能评价方法 - Google Patents
一种SQL Server数据库性能评价方法 Download PDFInfo
- Publication number
- CN117056182B CN117056182B CN202211403366.4A CN202211403366A CN117056182B CN 117056182 B CN117056182 B CN 117056182B CN 202211403366 A CN202211403366 A CN 202211403366A CN 117056182 B CN117056182 B CN 117056182B
- Authority
- CN
- China
- Prior art keywords
- sec
- performance
- sql server
- database
- lock
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000011156 evaluation Methods 0.000 title claims abstract description 20
- 238000000034 method Methods 0.000 claims abstract description 6
- 230000000737 periodic effect Effects 0.000 claims description 4
- 238000012360 testing method Methods 0.000 claims description 4
- 238000013475 authorization Methods 0.000 claims description 2
- 239000002131 composite material Substances 0.000 claims description 2
- 238000002546 full scan Methods 0.000 claims description 2
- 238000005259 measurement Methods 0.000 claims description 2
- 230000007547 defect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/30—Monitoring
- G06F11/34—Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
- G06F11/3409—Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/21—Design, administration or maintenance of databases
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/28—Databases characterised by their database models, e.g. relational or object models
- G06F16/284—Relational databases
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Databases & Information Systems (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
本发明提出一种SQL Server数据库性能评价方法,该方法根据SQL Server数据库运行过程中的关键指标,对SQL Server数据库的性能进行综合评价,方便用户实时了解SQL Server数据库的健康状态。采用该性能评价方法后,可以根据SQL Server数据库的关键性能指标快速得到SQL Server数据库的综合性能,便于数据库管理员及时查看数据库性能瓶颈,并解决发现的问题。
Description
技术领域
本发明涉及数据库技术领域,具体地涉及一种SQL Server数据库性能评价领域。
背景技术
随着信息技术的飞速发展,各行各业都积累了大量数据。数据的存储方式多种多样,其中数据库最为普遍,而SQL Server数据库是众多数据库类型的代表之一。
SQL Server是微软公司推出的一种关系型数据库管理系统,为关系型数据和结构化数据提供了更安全可靠的存储功能。从SQL Server 2017版本开始,SQL Server数据库实现了对Linux操作系统的支持,使得SQL Server数据库的应用限制得以突破,应用范围进一步扩大。
SQL Server数据库可以实现对大规模结构化数据的存储。如果数据规模过大,或者数据库设计不够合理,可能导致SQL Server出现性能瓶颈。传统的数据库性能监控方式由数据库管理员负责监督SQL Server数据库的运行状况,但这种方式存在一些弊端,如SQLServer数据库的性能指标比较多,数据库管理员在检查时只能逐个指标进行检查,定位问题指标时存在困难。
附图说明
图1为正态分布概率表。
发明内容
为解决现有技术中存在的问题,本发明提出一种SQL Server数据库性能评价方法,该方法根据SQL Server数据库运行过程中的关键指标,对SQL Server数据库的性能进行综合评价,方便用户实时了解SQL Server数据库的健康状态。具体步骤包括:
(1)将SQL Server数据库关键性能指标表示为ei,其中1≤i≤c,c为指标总数。按照设定的时间间隔,周期性获得受控数据库的ei指标值,并存储在本地数据库中;
(2)对每一项性能指标的数值ei进行评价:
i.获取性能指标ei在过去一周内的周期性测量值,记为ei1,ei2,…,eim,其中m为指标ei的取值次数;
ii.计算平均值
iii.计算每个测量值eij对应的剩余误差其中j=1,2,…,m;
iv.计算性能指标ei对应的标准偏差
v.对于性能指标ei的一个新的测试值ei_new,计算标准化以后的取值根据计算出的/>值,查正态分布概率表可得概率P(ei<=ei_new),性能指标ei的评价记为si=200×(1-P(ei<=ei_new))。
(3)计算每一项性能指标的权重wi,计算方法为:
(4)计算SQL Server数据库的性能综合评价w=wi×si。
在本发明提出的性能评价方法中,SQL Server数据库关键性能指标包括
(1)全表扫描频率Full Scans/sec;(2)缓冲区缓存命中率Buffer Cache HitRatio;(3)读的页数/秒Page Reads/sec;(4)写的页数/秒Page Writes/sec;(5)惰性写/秒Lazy Writes/sec;(6)缓存命中率Cache Hit Ratio;(7)平均闩等待Average Latch WaitTime;(8)闩等待/秒Latch Waits/sec;(9)用户连接数User Connections;(10)锁请求数/秒Lock Requests/sec;(11)超时锁请求数/秒Lock Timeouts/sec;(12)锁等待/秒LockWaits/sec;(13)平均等待时间Average Wait Time;(14)死锁请求数/秒Number ofDeadlocks/sec;(15)内存授权待定进程总数Memory Grants Pending;(16)锁块数LockBlocks;(17)总服务器内存Total Server Memory;(18)批请求次数/秒Batch Requests/sec;(19)编译数/秒SQL Compilations/sec。
采用该性能评价方法后,可以根据SQL Server数据库的关键性能指标快速得到SQL Server数据库的综合性能,便于数据库管理员及时查看数据库性能瓶颈,并解决发现的问题。
具体实施方式
(1)将SQL Server数据库关键性能指标表示为ei,其中1≤i≤c,c为指标总数(本发明中为19)。按照设定的时间间隔,周期性获得受控数据库的ei指标值,并存储在本地数据库中。
(2)对每一项性能指标的数值ei进行评价:
i.获取性能指标ei在过去一周内的周期性测量值,记为ei1,ei2,…,eim,其中m为指标ei的取值次数;以e3为例,假设e3在过去一周内的周期性测量值为70,80,70,76,78,82,88,76。
ii.计算平均值可以计算e3的平均值为:/>
iii.计算每个测量值eij对应的剩余误差其中j=1,2,…,m;可以计算e3j对应的剩余误差分别为:-7.5,2.5,-7.5,-1.5,0.5,4.5,10.5,-1.5。
iv.计算性能指标ei对应的标准偏差可以计算
e3的标准偏差σ3=36.2857。
v.对于性能指标ei的一个新的测试值ei_new,计算标准化以后的取值
根据计算出的/>值,查图1中的正态分布概率表可得概率P(ei<=ei_new),性能指标ei的评价记为si=200×(1-
P(ei<=ei_new))。假设e3的一个新的测试值e3_new=90,则可计算
查如下的正态分布概率表可得概率P(e3<=e3_new)
为0.6331,性能指标e3的评价记为s3=73.38。同理,可以计算出其他指标的评价,假设其他指标的评价分别为:s1=79.16,s2=74.81,s4=80.05,
s5=82.75,s6=80.29,s7=78.09,s8=83.09,s9=81.27,s10=77.2,s11=73.91,
s12=78.21,s13=78.68,s14=80.04,s15=82.55,s16=79.37,s17=79.52,
s18=74.64,s19=78.95。
(3)计算每一项性能指标的权重wi,计算方法为: 计算出所有指标的评价,可以计算每个性能指标的权重wi分别为:0.05,0.06,0.07,0.05,0.04,0.05,0.05,0.04,0.05,0.06,0.06,0.05,0.05,0.05,0.04,0.05,0.05,0.06,0.05。
(4)计算SQL Server数据库的性能综合评价w=wi×si,求得性能综合评价为76.79。
Claims (2)
1.一种SQL Server数据库性能评价方法,其特征在于,该方法具体步骤包括:
(1)将SQL Server数据库关键性能指标表示为ei,其中1≤i≤c,c为指标总数;按照设定的时间间隔,周期性获得受控数据库的ei指标值,并存储在本地数据库中;
(2)对每一项性能指标的数值ei进行评价:
i.获取性能指标ei在过去一周内的周期性测量值,记为ei1,ei2,…,eim,
其中m为指标ei的取值次数;
ii.计算平均值
iii.计算每个测量值eij对应的剩余误差其中j=1,2,…,m;
iv.计算性能指标ei对应的标准偏差
v.对于性能指标ei的一个新的测试值ei_new,计算标准化以后的取值根据计算出的/>值,查正态分布概率表可得概率P(ei<=ei_new),性能指标ei的评价记为si=200×(1-P(ei<=ei_new));
(3)计算每一项性能指标的权重wi,计算方法为:
(4)计算SQL Server数据库的性能综合评价w=wi×si。
2.根据权利要求1中的一种SQL Server数据库性能评价方法,其特征在于:SQL Server数据库关键性能指标包括:(1)全表扫描频率Full Scans/sec;(2)缓冲区缓存命中率Buffer Cache Hit Ratio;(3)读的页数/秒Page Reads/sec;(4)写的页数/秒PageWrites/sec;(5)惰性写/秒Lazy Writes/sec;(6)缓存命中率Cache Hit Ratio;(7)平均闩等待Average Latch Wait Time;(8)闩等待/秒Latch Waits/sec;(9)用户连接数UserConnections;(10)锁请求数/秒Lock Requests/sec;(11)超时锁请求数/秒LockTimeouts/sec;(12)锁等待/秒Lock Waits/sec;(13)平均等待时间Average Wait Time;(14)死锁请求数/秒Number of Deadlocks/sec;(15)内存授权待定进程总数MemoryGrants Pending;(16)锁块数Lock Blocks;(17)总服务器内存Total Server Memory;(18)批请求次数/秒Batch Requests/sec;(19)编译数/秒SQL Compilations/sec。
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211403366.4A CN117056182B (zh) | 2023-07-13 | 2023-07-13 | 一种SQL Server数据库性能评价方法 |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211403366.4A CN117056182B (zh) | 2023-07-13 | 2023-07-13 | 一种SQL Server数据库性能评价方法 |
Publications (2)
Publication Number | Publication Date |
---|---|
CN117056182A CN117056182A (zh) | 2023-11-14 |
CN117056182B true CN117056182B (zh) | 2024-05-03 |
Family
ID=88661422
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211403366.4A Active CN117056182B (zh) | 2023-07-13 | 2023-07-13 | 一种SQL Server数据库性能评价方法 |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117056182B (zh) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109992569A (zh) * | 2019-02-19 | 2019-07-09 | 平安科技(深圳)有限公司 | 集群日志特征提取方法、装置及存储介质 |
CN110096491A (zh) * | 2019-04-02 | 2019-08-06 | 南京信息职业技术学院 | 数据库性能指标预测方法及系统 |
CN110737648A (zh) * | 2019-09-17 | 2020-01-31 | 平安科技(深圳)有限公司 | 性能特征降维方法及装置、电子设备及存储介质 |
CN116166513A (zh) * | 2023-01-30 | 2023-05-26 | 浪潮卓数大数据产业发展有限公司 | 一种针对数据库性能测试的评价方法、设备及存储介质 |
CN116245406A (zh) * | 2023-02-09 | 2023-06-09 | 江苏省工商行政管理局信息中心 | 基于运维质量管理数据库的软件运维质量评价方法及系统 |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080033991A1 (en) * | 2006-08-03 | 2008-02-07 | Jayanta Basak | Prediction of future performance of a dbms |
-
2023
- 2023-07-13 CN CN202211403366.4A patent/CN117056182B/zh active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109992569A (zh) * | 2019-02-19 | 2019-07-09 | 平安科技(深圳)有限公司 | 集群日志特征提取方法、装置及存储介质 |
CN110096491A (zh) * | 2019-04-02 | 2019-08-06 | 南京信息职业技术学院 | 数据库性能指标预测方法及系统 |
CN110737648A (zh) * | 2019-09-17 | 2020-01-31 | 平安科技(深圳)有限公司 | 性能特征降维方法及装置、电子设备及存储介质 |
CN116166513A (zh) * | 2023-01-30 | 2023-05-26 | 浪潮卓数大数据产业发展有限公司 | 一种针对数据库性能测试的评价方法、设备及存储介质 |
CN116245406A (zh) * | 2023-02-09 | 2023-06-09 | 江苏省工商行政管理局信息中心 | 基于运维质量管理数据库的软件运维质量评价方法及系统 |
Non-Patent Citations (1)
Title |
---|
轨道交通列车制动系统的可视化数据处理软件设计及应用;陈腾鹏;吴萌岭;左建勇;吴海岭;;电力机车与城轨车辆;20100630(第06期);45-48 * |
Also Published As
Publication number | Publication date |
---|---|
CN117056182A (zh) | 2023-11-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9542424B2 (en) | Lifecycle-based horizontal partitioning | |
US6374232B1 (en) | Method and mechanism for retrieving values from a database | |
US7788243B2 (en) | System and methods for optimizing data transfer among various resources in a distributed environment | |
US6934717B1 (en) | Database access | |
US20180285414A1 (en) | Database management system cluster node subtasking data query | |
US8429134B2 (en) | Distributed database recovery | |
US20100257181A1 (en) | Dynamic Hash Table for Efficient Data Access In A Relational Database System | |
CN107491487B (zh) | 一种全文数据库架构及位图索引创建、数据查询方法、服务器及介质 | |
US9916313B2 (en) | Mapping of extensible datasets to relational database schemas | |
US20120323971A1 (en) | Optimizing data storage and access of an in-memory database | |
US20070185912A1 (en) | Off-loading I/O and computationally intensive operations to secondary systems | |
US20150347492A1 (en) | Representing an outlier value in a non-nullable column as null in metadata | |
CA2455348A1 (en) | Integrating tablespaces with different block sizes | |
US20240004852A1 (en) | Confidence-based database management systems and methods for use therewith | |
US7437525B2 (en) | Guaranteed undo retention | |
CA2414980A1 (en) | Deferred incremental integrity maintenance of base tables having contiguous data blocks | |
CN117056182B (zh) | 一种SQL Server数据库性能评价方法 | |
US8548980B2 (en) | Accelerating queries based on exact knowledge of specific rows satisfying local conditions | |
CN111680083A (zh) | 智能化多级政府财政数据采集系统及数据采集方法 | |
US20120221293A1 (en) | Performance logging framework | |
Kim | On three major holes in data warehousing today | |
CN115827653B (zh) | 一种用于htap和海量数据的纯列式更新方法及装置 | |
CN115905259B (zh) | 一种支持行级并发控制的纯列式更新方法及装置 | |
CN113076311B (zh) | 一种分布式数据库 | |
CN116975111A (zh) | 一种时序数据库的元数据缓存管理方法及装置 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |