博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
mysql qps 计算_请问MYSQL数据库QPS,TPS采用哪种计算方式?
阅读量:6904 次
发布时间:2019-06-27

本文共 834 字,大约阅读时间需要 2 分钟。

Questions 其实包括了 很多sql语句的执行,ddl, dml, show, set等。

比如 SHOW GLOBAL STATUS LIKE 'Questions';也会计算在内的。

The number of statements executed by the server. This includes only statements sent to the server by clients and not statements executed within stored programs, unlike the [`Queries`](https://dev.mysql.com/doc/refman/8.0/en/server-status-variables.html#statvar_Queries) variable. This variable does not count `COM_PING`, `COM_STATISTICS`, `COM_STMT_PREPARE`, `COM_STMT_CLOSE`, or `COM_STMT_RESET` commands.

The discussion at the beginning of this section indicates how to relate this statement-counting status variable to other such variables.

QPS,如果不考虑存储过程的执行,可以采用 QPS=(Com_select + Com_insert + Com_delete + Com_update) / Uptime 。

不过,要相对准确表达QPS, 采用 QPS=Questions/Uptime 计算。

TPS的话,采用TPS=(Handler_commit + Handler_rollback)/Uptime 会更加准确。

转载地址:http://hoodl.baihongyu.com/

你可能感兴趣的文章
【2018年12月10日】A股最便宜的股票
查看>>
Golang编程经验总结
查看>>
重启Oracle服务
查看>>
服务器意外关机,如何查看关机起因?
查看>>
杭电2049
查看>>
翻译的问题
查看>>
iOS的异步绘制--YYAsyncLayer源码分析
查看>>
RedHat Linux tftp服务器配置
查看>>
CS系统框架二(数据库配置)
查看>>
C#跨线程更改用户界面
查看>>
在windows下安装配置Ulipad
查看>>
理解JS回调函数
查看>>
WCF返回null超时
查看>>
通过纯代码方式发布WCF服务
查看>>
【C#学习笔记】Dictionary容器使用
查看>>
关于各网站回到顶部的细节功能
查看>>
JasonHelper.Escape 转换字符串为jason格式代码
查看>>
设计模式:简单工厂、工厂方法、抽象工厂之小结与区别 (转)
查看>>
C# 常用算法
查看>>
C# Remoting的一个简单例子
查看>>