1, 编辑/etc/mysql/mysql.cnf文件,在后面加上配置参数

#binlog configuration by myself
log_bin=/var/log/mysql/binlog
server_id=100


2, 重启mysql

systemctl stop mysql.service

systemctl start mysql.service


3, 查询二进制日志

使用[email protected]:/var/log/mysql# mysqlbinlog --no-defaults binlog.000004

或者:

MySQL配置binlog

相关文章:

  • 2022-12-23
  • 2022-01-07
  • 2021-11-12
  • 2022-01-29
猜你喜欢
  • 2021-10-10
  • 2022-12-23
  • 2021-08-03
  • 2021-04-23
  • 2022-12-23
  • 2022-12-23
  • 2022-03-01
相关资源
相似解决方案