aboutsummaryrefslogtreecommitdiffstats
path: root/manifests/profile
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2017-09-25 09:56:32 -0400
committerDamien Ciabrini <dciabrin@redhat.com>2017-11-06 12:15:31 +0100
commitdab23e1ba795ee004984cc6f2cbb9427b182f588 (patch)
tree9f11e31e5da1f6b597f3283502733874ca29eeeb /manifests/profile
parent6e27339c4037604d19444e7bf2709e59944d0c48 (diff)
Add new MySQL server option to mysql_bundle
Add innodb_flush_log_at_trx_commit from Id5a30f1daf978e094a74db2d284febbc9ae64bb3 to the container-specific mysql_bundle.pp Note that innodb_buffer_pool_size from Iabdcb6f76510becb98cba35c95db550ffce44ff3 should already be pulled at runtime from the base mysql.pp. Closes-Bug: #1730360 Change-Id: Iba164ddcc9b24ee231fb224b03ad8e7c123d5418 (cherry picked from commit 7de6d8d9f5687cdb7e1709a7e15e98184aa615f0)
Diffstat (limited to 'manifests/profile')
-rw-r--r--manifests/profile/pacemaker/database/mysql_bundle.pp87
1 files changed, 48 insertions, 39 deletions
diff --git a/manifests/profile/pacemaker/database/mysql_bundle.pp b/manifests/profile/pacemaker/database/mysql_bundle.pp
index 1bcdbbe..613be56 100644
--- a/manifests/profile/pacemaker/database/mysql_bundle.pp
+++ b/manifests/profile/pacemaker/database/mysql_bundle.pp
@@ -60,6 +60,13 @@
# connections from other nodes in the cluster.
# Defaults to hiera('mysql_bind_host')
#
+# [*innodb_flush_log_at_trx_commit*]
+# (Optional) Disk flush behavior for MySQL under Galera. A value of
+# '1' indicates flush to disk per transaction. A value of '2' indicates
+# flush to disk every second, flushing all unflushed transactions in
+# one step.
+# Defaults to hiera('innodb_flush_log_at_trx_commit', '1')
+#
# [*pcs_tries*]
# (Optional) The number of times pcs commands should be retried.
# Defaults to hiera('pcs_tries', 20)
@@ -71,16 +78,17 @@
#
#
class tripleo::profile::pacemaker::database::mysql_bundle (
- $mysql_docker_image = hiera('tripleo::profile::pacemaker::database::mysql_bundle::mysql_docker_image', undef),
- $control_port = hiera('tripleo::profile::pacemaker::database::mysql_bundle::control_port', '3123'),
- $bootstrap_node = hiera('mysql_short_bootstrap_node_name'),
- $bind_address = $::hostname,
- $ca_file = undef,
- $certificate_specs = hiera('tripleo::profile::base::database::mysql::certificate_specs', {}),
- $enable_internal_tls = hiera('enable_internal_tls', false),
- $gmcast_listen_addr = hiera('mysql_bind_host'),
- $pcs_tries = hiera('pcs_tries', 20),
- $step = Integer(hiera('step')),
+ $mysql_docker_image = hiera('tripleo::profile::pacemaker::database::mysql_bundle::mysql_docker_image', undef),
+ $control_port = hiera('tripleo::profile::pacemaker::database::mysql_bundle::control_port', '3123'),
+ $bootstrap_node = hiera('mysql_short_bootstrap_node_name'),
+ $bind_address = $::hostname,
+ $ca_file = undef,
+ $certificate_specs = hiera('tripleo::profile::base::database::mysql::certificate_specs', {}),
+ $enable_internal_tls = hiera('enable_internal_tls', false),
+ $gmcast_listen_addr = hiera('mysql_bind_host'),
+ $innodb_flush_log_at_trx_commit = hiera('innodb_flush_log_at_trx_commit', '1'),
+ $pcs_tries = hiera('pcs_tries', 20),
+ $step = Integer(hiera('step')),
) {
if $::hostname == downcase($bootstrap_node) {
$pacemaker_master = true
@@ -122,37 +130,38 @@ class tripleo::profile::pacemaker::database::mysql_bundle (
$mysqld_options = {
'mysqld' => {
- 'pid-file' => '/var/lib/mysql/mariadb.pid',
- 'skip-name-resolve' => '1',
- 'binlog_format' => 'ROW',
- 'default-storage-engine' => 'innodb',
- 'innodb_autoinc_lock_mode' => '2',
- 'innodb_locks_unsafe_for_binlog'=> '1',
- 'innodb_file_per_table' => 'ON',
- 'query_cache_size' => '0',
- 'query_cache_type' => '0',
- 'bind-address' => $bind_address,
- 'max_connections' => hiera('mysql_max_connections'),
- 'open_files_limit' => '-1',
- 'wsrep_on' => 'ON',
- 'wsrep_provider' => '/usr/lib64/galera/libgalera_smm.so',
- 'wsrep_cluster_name' => 'galera_cluster',
- 'wsrep_cluster_address' => "gcomm://${galera_nodes}",
- 'wsrep_slave_threads' => '1',
- 'wsrep_certify_nonPK' => '1',
- 'wsrep_max_ws_rows' => '131072',
- 'wsrep_max_ws_size' => '1073741824',
- 'wsrep_debug' => '0',
- 'wsrep_convert_LOCK_to_trx' => '0',
- 'wsrep_retry_autocommit' => '1',
- 'wsrep_auto_increment_control' => '1',
- 'wsrep_drupal_282555_workaround'=> '0',
- 'wsrep_causal_reads' => '0',
- 'wsrep_sst_method' => 'rsync',
- 'wsrep_provider_options' => "gmcast.listen_addr=tcp://${gmcast_listen_addr}:4567;${tls_options}",
+ 'pid-file' => '/var/lib/mysql/mariadb.pid',
+ 'skip-name-resolve' => '1',
+ 'binlog_format' => 'ROW',
+ 'default-storage-engine' => 'innodb',
+ 'innodb_autoinc_lock_mode' => '2',
+ 'innodb_locks_unsafe_for_binlog' => '1',
+ 'innodb_file_per_table' => 'ON',
+ 'innodb_flush_log_at_trx_commit' => $innodb_flush_log_at_trx_commit,
+ 'query_cache_size' => '0',
+ 'query_cache_type' => '0',
+ 'bind-address' => $bind_address,
+ 'max_connections' => hiera('mysql_max_connections'),
+ 'open_files_limit' => '-1',
+ 'wsrep_on' => 'ON',
+ 'wsrep_provider' => '/usr/lib64/galera/libgalera_smm.so',
+ 'wsrep_cluster_name' => 'galera_cluster',
+ 'wsrep_cluster_address' => "gcomm://${galera_nodes}",
+ 'wsrep_slave_threads' => '1',
+ 'wsrep_certify_nonPK' => '1',
+ 'wsrep_max_ws_rows' => '131072',
+ 'wsrep_max_ws_size' => '1073741824',
+ 'wsrep_debug' => '0',
+ 'wsrep_convert_LOCK_to_trx' => '0',
+ 'wsrep_retry_autocommit' => '1',
+ 'wsrep_auto_increment_control' => '1',
+ 'wsrep_drupal_282555_workaround' => '0',
+ 'wsrep_causal_reads' => '0',
+ 'wsrep_sst_method' => 'rsync',
+ 'wsrep_provider_options' => "gmcast.listen_addr=tcp://${gmcast_listen_addr}:4567;${tls_options}",
},
'mysqld_safe' => {
- 'pid-file' => '/var/lib/mysql/mariadb.pid',
+ 'pid-file' => '/var/lib/mysql/mariadb.pid',
}
}