Chinaunix首页 | 论坛 | 博客
  • 博客访问: 6559682
  • 博文数量: 1005
  • 博客积分: 8199
  • 博客等级: 中将
  • 技术积分: 13071
  • 用 户 组: 普通用户
  • 注册时间: 2010-05-25 20:19
个人简介

脚踏实地、勇往直前!

文章分类

全部博文(1005)

文章存档

2020年(2)

2019年(93)

2018年(208)

2017年(81)

2016年(49)

2015年(50)

2014年(170)

2013年(52)

2012年(177)

2011年(93)

2010年(30)

分类: Mysql/postgreSQL

2017-06-20 22:03:14

      搭建了mariadb galera集群后,整个集群停掉后如何启动呢,我们要先启动那个节点呢,今天我尝试把集群机器全部停掉,然后任意启动一个节点,发现报如下的错误:

170620 21:32:55 [ERROR] WSREP: It may not be safe to bootstrap the cluster from this node. It was not the last one to leave the cluster and may not contain all the updates. To force cluster bootstrap with this node, edit the grastate.dat file manually and set safe_to_bootstrap to 1 .

意思该节点不是最后一个离开集群的节点(最后停掉的节点),可能没有包含所有更新的数据,强制从该节点启动,需要手工编辑grastate.dat文件,设置safe_to_bootstrap=1,当然了,我们不需需要强制从该节点启动,我们逐一排查每个节点下的grastate.dat文件(该文件在data目录下),找到safe_to_bootstrap=1的节点,然后在该节点上启动即可.

比如我这里找到节点的是节点3
[root@hxl03 data]# more grastate.dat
# GALERA saved state
version: 2.1
uuid:    43caaa91-54bf-11e7-9321-c60bd8969b24
seqno:   2919
safe_to_bootstrap: 1

在该节点上先启动,然后逐一启动其他的节点.
[root@hxl03 bin]# ./mysqld_safe --defaults-file=/opt/mariadb-galera/mariadb-galera-10031/conf/my.cnf --wsrep-new-cluster --user=maria &

-- The End --
阅读(14996) | 评论(0) | 转发(0) |
0

上一篇:5.7.18 innodb表锁排查

下一篇:CentOS部署nginx

给主人留下些什么吧!~~