当前位置: 数据库>mysql
mysql手动删除BINLOG的方法
来源: 互联网 发布时间:2014-10-08
本文导语: 在MySQL中执行以下命令: 代码如下: PURGE {MASTER | BINARY} LOGS TO ‘log_name' PURGE {MASTER | BINARY} LOGS BEFORE ‘date' PURGE {MASTER|BINARY} LOGS BEFORE DATE_SUB(NOW(),INTERVAL 7 DAY);例如: 代码如下: mysql>PURGE MASTER LOGS TO ‘mysql-bin.010′; mysql>PURGE MASTER ...
在MySQL中执行以下命令:
代码如下:
PURGE {MASTER | BINARY} LOGS TO ‘log_name'
PURGE {MASTER | BINARY} LOGS BEFORE ‘date'
PURGE {MASTER|BINARY} LOGS BEFORE DATE_SUB(NOW(),INTERVAL 7 DAY);
例如:
代码如下:
mysql>PURGE MASTER LOGS TO ‘mysql-bin.010′;
mysql>PURGE MASTER LOGS BEFORE ‘2008-06-22 13:00:00′;
mysql>PURGE MASTER LOGS BEFORE DATE_SUB( NOW( ), INTERVAL 7 DAY);