Remember a performance test: mysql take up disk IO high resolution process

When a performance test and found that the mysql cpu usage is not high, but high disk io,

 

 Mysql is considered a slow start logging more, but the review found that the log is not much slower, but only one mysql.

Enter the instance, view sync_binlog variable

mysql> show variables like '%sync_binlog%'
    -> ;
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| sync_binlog   | 1     |
+---------------+-------+
1 row in set (0.01 sec)

mysql> 

 Discovery is set to 1, that is, each time a transaction is committed, will be binlog cache is written to disk, seriously affecting the efficiency of disk, set the variable to 1000, the problem is solved

Guess you like

Origin www.cnblogs.com/lily328/p/11988332.html