ansible-mysql/templates/etc/mysql/conf.d/09-galera.cnf.j2

35 lines
809 B
Plaintext
Raw Normal View History

#
# {{ ansible_managed }}
#
[mysqld]
# --------------------
# Galera config
# --------------------
# Global
wsrep_on=ON
wsrep_provider=/usr/lib/galera/libgalera_smm.so
2018-03-17 23:28:54 +07:00
wsrep_cluster_address=gcomm://{{ mariadb_galera_members | join(",") }}
wsrep_sst_method="{{ mariadb_wsrep_stt_method }}"
{% if mariadb_wsrep_cluster_name is defined %}
wsrep_cluster_name="{{ mariadb_wsrep_cluster_name }}"
{% endif %}
# Node Configuration
2018-03-17 23:28:54 +07:00
wsrep_node_address="{{ mariadb_wsrep_node_address | default(ansible_default_ipv4.address) }}"
wsrep_node_name="{{ mariadb_wsrep_node_name | default(ansible_fqdn) }}"
# --------------------
# Deps
# --------------------
binlog_format=ROW
default_storage_engine=InnoDB
innodb_autoinc_lock_mode=2
innodb_doublewrite=1
{% if mariadb_version == '10.0'%}
query_cache_size=0
{% endif %}