mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
MDEV-12218 Clean up InnoDB parameter validation
Bind more InnoDB parameters directly to MYSQL_SYSVAR and remove "shadow variables". innodb_change_buffering: Declare as ENUM, not STRING. innodb_flush_method: Declare as ENUM, not STRING. innodb_log_buffer_size: Bind directly to srv_log_buffer_size, without rounding it to a multiple of innodb_page_size. LOG_BUFFER_SIZE: Remove. SysTablespace::normalize_size(): Renamed from normalize(). innodb_init_params(): A new function to initialize and validate InnoDB startup parameters. innodb_init(): Renamed from innobase_init(). Invoke innodb_init_params() before actually trying to start up InnoDB. srv_start(bool): Renamed from innobase_start_or_create_for_mysql(). Added the input parameter create_new_db. SRV_ALL_O_DIRECT_FSYNC: Define only for _WIN32. xb_normalize_init_values(): Merge to innodb_init_param().
This commit is contained in:
26
mysql-test/suite/sys_vars/t/innodb_flush_method_func.test
Normal file
26
mysql-test/suite/sys_vars/t/innodb_flush_method_func.test
Normal file
@ -0,0 +1,26 @@
|
||||
--source include/have_innodb.inc
|
||||
# Embedded server tests do not support restarting.
|
||||
--source include/not_embedded.inc
|
||||
|
||||
call mtr.add_suppression("InnoDB: Failed to set .*DIRECT");
|
||||
--replace_result unbuffered fsync
|
||||
select @@innodb_flush_method;
|
||||
|
||||
create table t(a serial) engine=innodb;
|
||||
|
||||
# kill and restart
|
||||
FLUSH TABLES;
|
||||
let $shutdown_timeout= 0;
|
||||
let $restart_parameters=--innodb-flush-method=5;
|
||||
--source include/restart_mysqld.inc
|
||||
select @@innodb_flush_method;
|
||||
|
||||
insert into t values(0);
|
||||
# kill and restart
|
||||
FLUSH TABLES;
|
||||
let $shutdown_timeout= 0;
|
||||
let $restart_parameters=--innodb-flush-method=0;
|
||||
--source include/restart_mysqld.inc
|
||||
select @@innodb_flush_method;
|
||||
|
||||
drop table t;
|
Reference in New Issue
Block a user