Defauts mariadb's innodb_strict_mode to OFF

Recent mariadb (e.g. 10.3.27) added more DDL checks such as table
create/alter checks and table size checks which conflict with the
schema of a few OpenStack services after a FFU has upgraded the
database without changing the row format in use.

Since no data seems to be impacted, as an immediate measure,
force the innodb_strict_mode to OFF to ensure that all the db_sync
operations can succeed, until we come up with a permanent fix.

Closes-Bug: #1908232

Change-Id: I046dbbb0ffca935119c36d301c2ab7dba469de9c
This commit is contained in:
Damien Ciabrini 2020-12-14 16:08:42 +01:00 committed by Michele Baldessari
parent 1c27dd4603
commit fd43ab9b0f
1 changed files with 27 additions and 18 deletions

View File

@ -69,6 +69,13 @@
# When this occurs, the statement (not transaction) is rolled back.
# Defaults to undef.
#
# [*innodb_strict_mode*]
# (Optional) InnoDB strict mode enforcement. When set to 'ON', InnoDB
# performs validity checks on DDL statements such as table creation,
# or table row size. When set to 'OFF', the same checks only return
# warnings rather than error.
# Defaults to hiera('innodb_strict_mode', 'OFF')
#
# [*table_open_cache*]
# (Optional) Configure the number of open tables for all threads.
# Increasing this value increases the number of file descriptors that mysqld requires.
@ -112,6 +119,7 @@ class tripleo::profile::base::database::mysql (
$innodb_buffer_pool_size = hiera('innodb_buffer_pool_size', undef),
$innodb_log_file_size = undef,
$innodb_lock_wait_timeout = hiera('innodb_lock_wait_timeout', undef),
$innodb_strict_mode = hiera('innodb_strict_mode', 'OFF'),
$table_open_cache = undef,
$innodb_flush_method = undef,
$manage_resources = true,
@ -171,6 +179,7 @@ class tripleo::profile::base::database::mysql (
'innodb_file_per_table' => 'ON',
'innodb_log_file_size' => $innodb_log_file_size,
'innodb_lock_wait_timeout' => $innodb_lock_wait_timeout,
'innodb_strict_mode' => $innodb_strict_mode,
'log_warnings' => '1',
'table_open_cache' => $table_open_cache,
'innodb_flush_method' => $innodb_flush_method,