MySQL加入log_bin报错
MySQL中二进制日志功能默认是关闭的,查看各种开启方式后,确定在配置文件中加入如下配置来开启该功能:
[root@bogon /]# more /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
#socket=/var/lib/mysql/mysql.sock
socket=/var/run/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
ft_min_word_len = 1
symbolic-links=0
max_connections=1000
max_allowed_packet=100M
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd # Remove leading # to turn on a very important data integrity option: logging
# # changes to the binary log between backups.
log_bin=mysql-bin [mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid #
# include all files from the config directory
#
!includedir /etc/my.cnf.d
然后启动MySQL报错

解决方法:
在设置 log-bin 的时候同时需要设置 server-id 变量,即在配置文件中添加:
# Remove leading # to turn on a very important data integrity option: logging
# # changes to the binary log between backups.
log_bin=mysql-bin
server-id=1
启动成功:

MySQL加入log_bin报错的更多相关文章
- CentOS命令登录MySQL时,报错ERROR 1045 (28000):
CentOS命令登录MySQL时,报错ERROR 1045 (28000): Access denied for user root@localhost (using password: NO)错误解 ...
- mysql执行update报错1175解决方法
mysql执行update报错 update library set status=true where 1=1 Error Code: 1175. You are using safe update ...
- Mysql update in报错 [Err] 1093 - You can't specify target table 'company_info' for update in FROM clause
Mysql update in报错 解决方案: [Err] 1093 - You can't specify target table 'company_info' for update in FRO ...
- mysql执行update报错 Err] 1055 - 'information_schema.PROFILING.SEQ' isn't in GROUP BY
mysql执行update报错 Err] 1055 - 'information_schema.PROFILING.SEQ' isn't in GROUP BY 今天开发的同事发来如下错误信息,最最简 ...
- MySQL主从1205报错【转】
主从报错1205 Slave SQL thread retried transaction 10 time(s) in vain, giving up. Consider raising the va ...
- 远程登陆linux连接mysql root账号报错:2003-can't connect to MYSQL serve(转)
远程连接mysql root账号报错:2003-can't connect to MYSQL serve 1.远程连接Linux系统,登录数据库:mysql -uroot -p(密码) 2.修改roo ...
- 远程连接mysql root账号报错:2003-can't connect to MYSQL serve(转)
远程连接mysql root账号报错:2003-can't connect to MYSQL serve 1.远程连接Linux系统,登录数据库:mysql -uroot -p(密码) 2.修改roo ...
- MySQL数据源驱动报错
报错信息:MySQL数据源驱动报错: 1.mysql8.0以上版本需要连接数据库的JDBC驱动也是8.0版本以上 com.mysql.cj.jdbc.Driver 2.MySQL高版本需要指明是否需要 ...
- Linux下登陆MySQL时遇到报错"RROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES) "
前言 作者在2021-07-21时遇到 linux下登陆MySQL时遇到报错"RROR 1045 (28000): Access denied for user 'root'@'localh ...
随机推荐
- vue学习好文连接
1.什么是虚拟dom(VNode)? https://github.com/answershuto/learnVue/blob/master/docs/VNode%E8%8A%82%E7%82%B9. ...
- less和sass的区别
首先sass和less都是css的预编译处理语言,他们引入了mixins,参数,嵌套规则,运算,颜色,名字空间,作用域,JavaScript赋值等 加快了css开发效率,当然这两者都可以配合gulp和 ...
- LeetCode 86. Partition List 划分链表 C++
Given a linked list and a value x, partition it such that all nodes less than x come before nodes gr ...
- HTTPS 基本流程3
前文说到了6 组key material, 12个hash 值,非常迷惑, 今天才搞明白, 原来所有这些内容就是 对称密钥的内容. 上面的图 虽然不是很清晰,但是, 其实也已经写明白了, 就是 右边的 ...
- orcal - 伪列
数据伪劣 行号 ROWNUM SELECT ROWNUM, empno,ename,sal from emp; 取出第一行数据 SELECT ROWNUM, empno,ename,sal from ...
- C语言程序实现,统计字符串里面各个字符的个数在总字符个数中的比例,并打印输出。
#include<stdio.h> int main() { char *ppp= "aaassadddeeds"; ] = {};//存放字符 uint32 ccnt ...
- fdisk 分区及 swap
使用虚拟机创建挂载点 一,创建 windows 硬盘 创建
- OpenStack构架简介
OpenStack既是一个社区,也是一个项目和一个开源软件,提供开放源码软件,建立公共和私有云,它提供了一个部署云的操作平台或工具集,其宗旨在于:帮助组织运行为虚拟计算或存储服务的云,为公有云.私有云 ...
- 批处理BAT运行不显示DOS窗口的方法
新建记事本,写入下面内容 set ws=wscript.createobject("wscript.shell") ws.run "D:\scripts\svn-upda ...
- 《Java开发学习大纲文档》V7.0
<Java开发学习大纲文档>V7.0简介: 本文档是根据企业开发所需要掌握的知识点大纲进行总结汇编,是Java开发工程师必备知识体系,系统化学习针对性非常强,逻辑分析能力非常清晰;技术方面 ...