mysql show variables like_mysql中show status like和show variables like数据出处

不太清楚show variables与show status的内在区别,我的猜测是:

1.show variables读出的内容来自编译时设置的选项、配置文件、mysql命令行下的动态设置;

2.show status读出的内容则是动态的,是mysql运行时的动态变化:(1)可能来自进程运行时内部动态改变的参数信息;(2)可能来自数据库表:例如information_schema,performance_schema,mysql

08ef9de32536ff51a936b1a121a0730a.png

52e84a349347536c3b877f5c1670974f.png

不知道我的看法是不是正确,希望高手赐教。先谢过。

关于show variables官方文档有提到一些:

System variable information is also available from these sources:

Performance Schema tables. See Section 21.9.12, “Performance Schema System Variable Tables”.

The GLOBAL_VARIABLES and SESSION_VARIABLES tables. See Section 20.10, “The INFORMATION_SCHEMA GLOBAL_VARIABLES and SESSION_VARIABLES Tables”.

The mysqladmin variables command. See Section 4.5.2, “mysqladmin — Client for Administering a MySQL Server”.

关于show status官方文档描述如下:

tatus variable information is also available from these sources:

Performance Schema tables. See Section 21.9.13, “Performance Schema Status Variable Tables”.

The GLOBAL_STATUS and SESSION_STATUS tables. See Section 20.9, “The INFORMATION_SCHEMA GLOBAL_STATUS and SESSION_STATUS Tables”.

The mysqladmin extended-status command. See Section 4.5.2, “mysqladmin — Client for Administering a MySQL Server”.

看文档很重要,这是mysql官方的说明,附两个链接。

http://dev.mysql.com/doc/refman/5.7/en/server-system-variables.html

https://dev.mysql.com/doc/refman/5.7/en/performance-schema-variable-table-migration.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值