Allow tuning of Galera gcache size
Appropriate gcache.size values allow a cluster node to perform IST instead of SST if the writes occurred during its downtime do not exceed the size of the cache itself. This is especially beneficial during maintenance windows. Closes-Bug: #1939540 Change-Id: I483484c58ab703f3a4dcede636d733e23b051f63 (cherry picked from commit feed67dcc45eb3da818cc2ceac8cb3682a2b6364) (cherry picked from commit 1ce9d8855db0e282a4a0c47e9afdee3f7a102c39) (cherry picked from commit 165dcb2de05958c68e7e3ed46cd87b72c4f546fc) (cherry picked from commit 14d6f9ae31cfa067a6c75bf28d47ca3e052c29e1)
This commit is contained in:
parent
7f06784383
commit
a5e85d8445
@ -158,6 +158,11 @@
|
||||
# [*force_ocf*]
|
||||
# (optional) Use --force when creating the ocf resource via pcs
|
||||
# Defaults to false
|
||||
#
|
||||
# [*gcache_size*]
|
||||
# (optional) Controls the gcache size.
|
||||
# Defaults to undef
|
||||
#
|
||||
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'),
|
||||
@ -188,6 +193,7 @@ class tripleo::profile::pacemaker::database::mysql_bundle (
|
||||
$open_files_limit = 16384,
|
||||
$promote_timeout = 300,
|
||||
$force_ocf = false,
|
||||
$gcache_size = undef,
|
||||
) {
|
||||
if $bootstrap_node and $::hostname == downcase($bootstrap_node) {
|
||||
$pacemaker_master = true
|
||||
@ -239,6 +245,12 @@ class tripleo::profile::pacemaker::database::mysql_bundle (
|
||||
}
|
||||
$cluster_host_map_string = join($host_map_array, ';')
|
||||
|
||||
if $gcache_size {
|
||||
$gcache_options = "gcache.size=${gcache_size};"
|
||||
} else {
|
||||
$gcache_options = ''
|
||||
}
|
||||
|
||||
if $enable_internal_tls {
|
||||
$tls_certfile = $certificate_specs['service_certificate']
|
||||
$tls_keyfile = $certificate_specs['service_key']
|
||||
@ -277,9 +289,9 @@ class tripleo::profile::pacemaker::database::mysql_bundle (
|
||||
$mysqld_options_sst = {}
|
||||
}
|
||||
if $ipv6 {
|
||||
$wsrep_provider_options = "gmcast.listen_addr=tcp://[::]:4567;${tls_options}"
|
||||
$wsrep_provider_options = "${gcache_options}gmcast.listen_addr=tcp://[::]:4567;${tls_options}"
|
||||
} else {
|
||||
$wsrep_provider_options = "gmcast.listen_addr=tcp://${gmcast_listen_addr}:4567;${tls_options}"
|
||||
$wsrep_provider_options = "${gcache_options}gmcast.listen_addr=tcp://${gmcast_listen_addr}:4567;${tls_options}"
|
||||
}
|
||||
|
||||
$mysqld_options_mysqld = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user