MYSQL 中binlog 参数的记录

http://dev.mysql.com/doc/refman/5.7/en/replication-options-binary-log.html

 binlog_cache_size

Command-Line Format --binlog_cache_size=#
System Variable Name binlog_cache_size
Variable Scope Global
Dynamic Variable Yes
Permitted Values (32-bit platforms) Type integer
Default 32768
Min Value 4096
Max Value 4294967295
Permitted Values (64-bit platforms) Type integer
Default 32768
Min Value 4096
Max Value 18446744073709551615

要注意的是,SIZE的单位是BYTE.

32768是指容量为32k。 

参见http://blog.csdn.net/lxpbs8851/article/details/38455223

 

show status like '%binlog%';

stmt就是statement的意思

Binlog_cache_disk_use  (事务类)二进志日志缓存的已经存在硬盘的条数 

Binlog_cache_use    (事务类)二进制日志已缓存的条数(内存中)    注意,这个不是容量,而是事务个数。每次有一条事务提交,都会有一次增加

Binlog_stmt_cache_disk_use  (非事务类)二进志日志缓存的已经存在硬盘的条数  

Binlog_stmt_cache_use  (非事务类)二进制日志已缓存的条数(内存中) 非事务型的语句,都存在这儿,比如MYISAM引擎的表,插入记录就存在这儿


binlog_cache_use和binlog_cache_disk_use两者结合可以用来调整binlog_cache_size的大小
binglog_stmt_cache_use和binlog_stmt_cache_disk_use两者结合可以有来调整 binlog_stmt_cache_size的大小

这两个值是单独设置的。

 感谢 http://blog.itpub.net/25099483/viewspace-1469049/

posted @ 2016-04-26 10:48  一眼前望,一眼自省  阅读(3052)  评论(0编辑  收藏  举报