The following procedure describes how to bootstrap (restart) a Distributed DDNS database cluster when nodes in the desired cluster are running, but are disconnected from each other. This is sometimes called a "split brain" situation.
If all nodes are disconnected from each other, follow the instructions in All nodes are disconnected from each other.
If some nodes are still connected to each other, follow the instructions in Some nodes remain connected.
All nodes are disconnected from each other
docker exec -it <node-container-name> mariadb
SET GLOBAL wsrep_provider_options='pc.bootstrap=true';
Some nodes remain connected
If a network error prevents individual nodes from communicating with the cluster, those nodes will automatically rejoin the cluster when the network connection is restored. No additional work is required.
If you ended up with multiple active cluster instances (such as nodes 1 and 2 in one instance, but nodes 3 and 4 on a separate cluster instance), do the following:
Choose the bigger cluster to be the final data cluster.
- Stop each node in other clusters. To do so, run the docker
stop
command for each node:docker stop <Node container name>
-
After all nodes except for those in the final cluster are stopped, start each stopped node with the docker
start
command:docker start <Node container name>
Each node will automatically locate and sync with the active data cluster. Make sure you wait for each node to fully start and sync with the rest of the cluster before starting another node.