From 9d9925ec86bb779c60655bbf487d7921f22a36eb Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Mon, 19 Mar 2018 06:21:30 +0100 Subject: Include peer-finder and modify to match also IPs in order to support hostNetwork configuration --- .../share/container-scripts/mysql/galera-init/60-galera-config.sh | 2 +- .../share/container-scripts/mysql/galera-init/galera.cnf.template | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'root-galera/usr/share/container-scripts/mysql/galera-init') diff --git a/root-galera/usr/share/container-scripts/mysql/galera-init/60-galera-config.sh b/root-galera/usr/share/container-scripts/mysql/galera-init/60-galera-config.sh index 3b9fa31..e6cce5a 100644 --- a/root-galera/usr/share/container-scripts/mysql/galera-init/60-galera-config.sh +++ b/root-galera/usr/share/container-scripts/mysql/galera-init/60-galera-config.sh @@ -1,5 +1,5 @@ if [ -v POD_NAMESPACE ]; then - export MYSQL_GALERA_CLUSTER="$(hostname -f | cut -d'.' -f2)" + [ -v MYSQL_GALERA_CLUSTER ] || export MYSQL_GALERA_CLUSTER="$(hostname -f | cut -d'.' -f2)" log_info 'Processing basic Galera configuration files ...' envsubst < ${CONTAINER_SCRIPTS_PATH}/galera-init/galera.cnf.template > /etc/my.cnf.d/galera.cnf diff --git a/root-galera/usr/share/container-scripts/mysql/galera-init/galera.cnf.template b/root-galera/usr/share/container-scripts/mysql/galera-init/galera.cnf.template index e1013d7..b45dc85 100644 --- a/root-galera/usr/share/container-scripts/mysql/galera-init/galera.cnf.template +++ b/root-galera/usr/share/container-scripts/mysql/galera-init/galera.cnf.template @@ -3,11 +3,17 @@ wsrep_on = ON wsrep_provider = /usr/lib64/galera-3/libgalera_smm.so wsrep_sst_auth=${MYSQL_GALERA_USER}:${MYSQL_GALERA_PASSWORD} wsrep_cluster_name=${MYSQL_GALERA_CLUSTER} -#wsrep_provider_options="gcache.size=300M; gcache.page_size=300M" +#wsrep_provider_options="gcache.size=500M; gcache.page_size=500M" wsrep_sst_method = xtrabackup-v2 default_storage_engine = innodb binlog_format = row +#MySQL tuning +#max_threads = 128 +#key_buffer_size = 1024K +#sort_buffer_size = 1024K +#read_buffer_size = 1024K + # Performance settings innodb_autoinc_lock_mode = 2 innodb_flush_log_at_trx_commit = 0 -- cgit v1.2.3