diff --git a/config.yaml b/config.yaml index 8a5c8e0..17b996d 100644 --- a/config.yaml +++ b/config.yaml @@ -227,6 +227,16 @@ options: implication of this is one can set configuration values that could lead to memory exhaustion during run time as memory is not allocated at startup time. + pxc-strict-mode: + type: string + default: enforcing + description: | + Configures pxc_strict_mode (https://www.percona.com/doc/percona-xtradb-cluster/LATEST/features/pxc-strict-mode.html) + Valid values are 'disabled', 'permissive', 'enforcing' and 'master.' + Defaults to 'enforcing', as this is what PXC5.7 on bionic (and above) + does. + This option is ignored on PXC < 5.7 (xenial defaults to 5.6, trusty + defaults to 5.5) tuning-level: type: string default: safest diff --git a/hooks/percona_hooks.py b/hooks/percona_hooks.py index 25e9de5..9b0788e 100755 --- a/hooks/percona_hooks.py +++ b/hooks/percona_hooks.py @@ -216,7 +216,7 @@ def render_config(hosts=None): context['default_storage_engine'] = 'InnoDB' context['wsrep_log_conflicts'] = True context['innodb_autoinc_lock_mode'] = '2' - context['pxc_strict_mode'] = 'ENFORCING' + context['pxc_strict_mode'] = config('pxc-strict-mode') context.update(PerconaClusterHelper().parse_config()) render(os.path.basename(config_file), config_file, context, perms=0o444)