Perform a manual node provision. This guide details the steps to manually backup a donor and restore it to a joiner node in a Galera Cluster.
Sometimes it can be helpful to perform a "manual SST" when Galera's normal SSTs fail. This can be especially useful when the cluster's is very large, since a normal SST can take a long time to fail in that case.
A manual SST essentially consists of taking a backup of the donor, loading the backup on the joiner, and then manually editing the cluster state on the joiner node. This page will show how to perform this process with .
For example, a very common version number is "2.1".
mariadb_backup_galera_infoMariaDB 11.3 and earlier: xtrabackup_galera_info
For MariaDB 11.4 and later:
For MariaDB 11.3 and earlier:
The file contains the values of the wsrep_local_state_uuid and wsrep_last_committed status variables. The values are written in the following format:
For example:
On the joiner node, verify that the node does not need to perform a normal SSTs due to the manual SST.
sudo tee $MYSQL_BACKUP_DIR/grastate.dat <<EOF
# GALERA saved state
version: 2.1
uuid: d38587ce-246c-11e5-bcce-6bbd0831cc0f
seqno: 1352215
safe_to_bootstrap: 0
EOFMYSQL_DATADIR=/var/lib/mysql
rm -Rf $MYSQL_DATADIR/*mariadb-backup --copy-back \
--target-dir=$MYSQL_BACKUP_DIRchown -R mysql:mysql $MYSQL_DATADIR/systemctl start mariadbtail -f /var/log/mysql/mysqld.logmariadb-backup --versionMYSQL_BACKUP_DIR=/mysql_backup
mkdir $MYSQL_BACKUP_DIRDB_USER=sstuser
DB_USER_PASS=password
mariadb-backup --backup --galera-info \
--target-dir=$MYSQL_BACKUP_DIR \
--user=$DB_USER \
--password=$DB_USER_PASSsystemctl status mariadbMYSQL_BACKUP_DIR=/mysql_backup
mkdir $MYSQL_BACKUP_DIROS_USER=dba
JOINER_HOST=dbserver2.mariadb.com
rsync -av $MYSQL_BACKUP_DIR/* ${OS_USER}@${JOINER_HOST}:${MYSQL_BACKUP_DIR}mariadb-backup --prepare \
--target-dir=$MYSQL_BACKUP_DIRMYSQL_DATADIR=/var/lib/mysql
cat $MYSQL_DATADIR/grastate.dat | grep versioncat $MYSQL_BACKUP_DIR/mariadb_backup_galera_infocat $MYSQL_BACKUP_DIR/xtrabackup_galera_infowsrep_local_state_uuid:wsrep_last_committedd38587ce-246c-11e5-bcce-6bbd0831cc0f:1352215