Starting a MariaDB Galera Cluster node means to start a MariaDB server so that we can call the mysqld
binary or the mysqld_safe
script.
Before starting a node for the first time, we should prepare the configuration file. The following example shows a minimal configuration:
wsrep_provider=/usr/lib/galera/libgalera_smm.so default_storage_engine=InnoDB binlog_format=ROW innodb_autoinc_lock_mode=2 innodb_doublewrite=0 innodb_support_xa=0 query_cache_size=0
Here's an explanation of the options we set:
The
wsrep_provider
option is the most important. It tells Galera where thewsrep
library is located. Its path depends on your system.Since storage engines other than InnoDB should not be used, it is important to set
default_storage_engine
correctly.The
binlog_format
variable is set to the only allowed value,ROW
.The InnoDB doublewrite buffer and XA transactions are not supported in Galera.
The query cache is not supported.
When...