Get the App
SLTechnology News&Howtos  ›  Database  › 

Several nodes in docker went down unexpectedly. Pxc failed to start.

Shulou Source: shulou.com Published: 2022-06-01 08:07:50 10月03日 Update

Docker is down unexpectedly, and PXC can't start the solution.

Due to unexpected downtime of the docker start pxc node, the solution is as follows

Find any data volume mapping directory from the node and modify the parameters

[root@izuf64gdegum84eku07pljz ~] # docker volume × × pect v1 [{"CreatedAt": "2019-06-14T13:13:17+08:00", "Driver": "local", "Labels": {}, "Mountpoint": "/ var/lib/docker/volumes/v1/_data", "Name": "v1", "Options": {}, "Scope": "local"}]

Modify the grastate.dat configuration file (this is a special security mechanism for data consistency synchronization in pxc clusters)

# GALERA saved stateversion: 2.1uuid: f5cf24ff-8e62-11e9-a3b5-df56c6b933c6seqno:-1safe_to_bootstrap: 1 / / change here to 1 start node to docker start pxc node

Note:

Method 1:

PXC clusters are unavailable only when more than half of the nodes are down. This is to avoid deploying PXC clusters in remote computer rooms. Due to network failures, a PXC cluster is split into two clusters. So it's okay to hang up one or two nodes, as long as there are no more than half of the nodes.

Method 2: you can also delete containers and data volumes and recreate them, because the data volumes on the host will not be deleted, re-create containers for mapping, and the data will not be lost.

Tags: Nodes clusters data methods accidents two containers this is special consistent secure nothing consistency parameters only host remote failure quantity file Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MySQL Docker Shulou Information Linux MariaDB