Recovering from full cluster shutdown

Posted on Tue 04 December 2012 in hints-and-kinks • Tagged with Galera, MySQL, Pacemaker

If at any time all of the nodes in your cluster have been taken down, it is necessary to re-initialize the Galera replication state. In effect, this is identical to bootstrapping the cluster.

Start by manually bringing up the cluster IP on one of your nodes:

ip address add 192 …

Continue reading

Setting Galera-specific MySQL options

Posted on Tue 04 December 2012 in hints-and-kinks • Tagged with Galera, MySQL, Pacemaker

Now you can proceed with setting Galera specifics in your MySQL configurations.

Create a configuration file, identical on all cluster nodes, named /etc/mysql/conf.d/galera.cnf with the following content:

[mysqld]
bind_address=0.0.0.0
binlog_format=ROW
default_storage_engine=InnoDB
innodb_autoinc_lock_mode=2
innodb_locks_unsafe_for_binlog=1

Create another configuration file …


Continue reading

Starting Pacemaker

Posted on Tue 04 December 2012 in hints-and-kinks • Tagged with Galera, MySQL, Pacemaker

Once Corosync is running, you are able to start the Pacemaker cluster resource manager on all cluster nodes:

service pacemaker start

Once cluster startup is completed, you should see output similar to the following when invoking the crm_mon utility:

============
Last updated: Mon Dec  3 15:37:59 2012
Last change …

Continue reading

Testing resource recovery

Posted on Tue 04 December 2012 in hints-and-kinks • Tagged with Galera, MySQL, Pacemaker

If MySQL happens to die in your cluster, Pacemaker will automatically recover the service in place. To test this, select any node on your cluster and send the mysqld process a KILL signal:

killall -KILL mysqld

Then, monitor your cluster status with crm_mon -rf. After a few seconds, you should …


Continue reading

MySQL High Availability Deep Dive

Posted on Mon 03 December 2012 in presentations • Tagged with Conference, MySQL, Pacemaker, Galera

This is a tutorial that Yves Trudeau and I presented at the Percona Live UK 2012 conference in London. It covers Pacemaker integration with DRBD, MySQL Replication, and Galera.


This article originally appeared on the hastexo.com website (now defunct).