当前位置:Gxlcms > 数据库问题 > innodb_flush_log_at_trx_commit理解

innodb_flush_log_at_trx_commit理解

时间:2021-07-01 10:21:17 帮助过:3人阅读

如果innodb_flush_log_at_trx_commit设置为0,log buffer将每秒一次地写入log file中,并且log file的flush(刷到磁盘)操作同时进行.该模式下,在事务提交的时候,不会主动触发写入磁盘的操作。
如果innodb_flush_log_at_trx_commit设置为1,每次事务提交时MySQL都会把log buffer的数据写入log file,并且flush(刷到磁盘)中去.
如果innodb_flush_log_at_trx_commit设置为2,每次事务提交时MySQL都会把log buffer的数据写入log file.但是flush(刷到磁盘)操作并不会同时进行。


本文出自 “dba天空” 博客,请务必保留此出处http://9425473.blog.51cto.com/9415473/1670784

innodb_flush_log_at_trx_commit理解

标签:mysql

人气教程排行