From 013dcdbd67ad499730d25b618afbb7afa169552b Mon Sep 17 00:00:00 2001 From: Omer BarNir Date: Thu, 28 Jan 2010 22:33:00 -0800 Subject: [PATCH 1/3] Modified and added tests following review of WL#4738. - Added tests for innodb and semisync plugin - Modified existing tests to include variable values in I_S tables - Updated the all_vars test to include optional checkes for INNODB and semisync plugin if loaded mysql-test/suite/sys_vars/r/innodb_adaptive_flushing_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_adaptive_hash_index_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_change_buffering_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_file_format_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_file_format_check_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_io_capacity_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_old_blocks_pct_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_old_blocks_time_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_read_ahead_threshold_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_read_io_threads_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_replication_delay_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_spin_wait_delay_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_stats_on_metadata_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_stats_sample_pages_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_strict_mode_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_thread_sleep_delay_basic.result: Updated result file mysql-test/suite/sys_vars/r/innodb_use_sys_malloc_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_version_basic.result: New result file mysql-test/suite/sys_vars/r/innodb_write_io_threads_basic.result: New result file mysql-test/suite/sys_vars/r/last_insert_id_basic.result: Updated result file mysql-test/suite/sys_vars/r/lc_messages_basic.result: Updated result file mysql-test/suite/sys_vars/r/log_slow_queries_basic.result: Updated result file mysql-test/suite/sys_vars/r/lower_case_file_system_basic.result: Updated result file mysql-test/suite/sys_vars/r/lower_case_table_names_basic.result: Updated result file mysql-test/suite/sys_vars/r/max_join_size_basic.result: Updated result file mysql-test/suite/sys_vars/r/old_alter_table_basic.result: Updated result file mysql-test/suite/sys_vars/r/optimizer_switch_basic.result: Updated result file mysql-test/suite/sys_vars/r/profiling_basic.result: Updated result file mysql-test/suite/sys_vars/r/profiling_history_size_basic.result: Updated result file mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result: Updated result file mysql-test/suite/sys_vars/r/rand_seed1_basic.result: Updated result file mysql-test/suite/sys_vars/r/rand_seed2_basic.result: Updated result file mysql-test/suite/sys_vars/r/relay_log_recovery_basic.result: Updated result file mysql-test/suite/sys_vars/r/rpl_semi_sync_master_enabled_basic.result: New result file mysql-test/suite/sys_vars/r/rpl_semi_sync_master_timeout_basic.result: New result file mysql-test/suite/sys_vars/r/rpl_semi_sync_master_trace_level_basic.result: New result file mysql-test/suite/sys_vars/r/rpl_semi_sync_master_wait_no_slave_basic.result: New result file mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_enabled_basic.result: New result file mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_trace_level_basic.result: New result file mysql-test/suite/sys_vars/r/sql_log_update_basic.result: Added check for variable values in I_S tables mysql-test/suite/sys_vars/r/sql_max_join_size_basic.result: Added check for variable values in I_S tables mysql-test/suite/sys_vars/r/sql_select_limit_basic.result: Added check for variable values in I_S tables mysql-test/suite/sys_vars/r/thread_cache_size_basic.result: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/all_vars-master.opt: Added opt file for all_vars.test mysql-test/suite/sys_vars/t/all_vars.test: Modified test to check for semisync plugin and innodb mysql-test/suite/sys_vars/t/innodb_adaptive_flushing_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_adaptive_hash_index_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_change_buffering_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_file_format_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_file_format_check_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_io_capacity_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_old_blocks_pct_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_old_blocks_time_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_read_ahead_threshold_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_read_io_threads_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_replication_delay_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_spin_wait_delay_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_stats_on_metadata_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_stats_sample_pages_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_strict_mode_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_thread_sleep_delay_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_use_sys_malloc_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_version_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/innodb_write_io_threads_basic.test: Added test for innodb variable mysql-test/suite/sys_vars/t/last_insert_id_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/lc_messages_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/log_slow_queries_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/lower_case_file_system_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/lower_case_table_names_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/max_join_size_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/old_alter_table_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/optimizer_switch_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/profiling_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/profiling_history_size_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test: Added check for variable values in I_S tables and check for session variable being numeric mysql-test/suite/sys_vars/t/rand_seed1_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/rand_seed2_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/relay_log_recovery_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic-master.opt: Added option file for semisync variable test mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test: Added test file for semisync variable mysql-test/suite/sys_vars/t/sql_log_update_basic.test: Added check for variable values in I_S tables and check for ON/OFF value changes mysql-test/suite/sys_vars/t/sql_max_join_size_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/sql_select_limit_basic.test: Added check for variable values in I_S tables mysql-test/suite/sys_vars/t/thread_cache_size_basic.test: Added check for variable values in I_S tables --- .../r/innodb_adaptive_flushing_basic.result | 92 +++++++++++++ .../r/innodb_adaptive_hash_index_basic.result | 92 +++++++++++++ .../r/innodb_change_buffering_basic.result | 63 +++++++++ .../r/innodb_file_format_basic.result | 59 ++++++++ .../r/innodb_file_format_check_basic.result | 59 ++++++++ .../r/innodb_io_capacity_basic.result | 69 ++++++++++ .../r/innodb_old_blocks_pct_basic.result | 82 +++++++++++ .../r/innodb_old_blocks_time_basic.result | 56 ++++++++ .../innodb_read_ahead_threshold_basic.result | 73 ++++++++++ .../r/innodb_read_io_threads_basic.result | 21 +++ .../r/innodb_replication_delay_basic.result | 56 ++++++++ .../r/innodb_spin_wait_delay_basic.result | 56 ++++++++ .../r/innodb_stats_on_metadata_basic.result | 92 +++++++++++++ .../r/innodb_stats_sample_pages_basic.result | 56 ++++++++ .../r/innodb_strict_mode_basic.result | 120 ++++++++++++++++ .../r/innodb_thread_sleep_delay_basic.result | 130 +++++++----------- .../r/innodb_use_sys_malloc_basic.result | 25 ++++ .../sys_vars/r/innodb_version_basic.result | 17 +++ .../r/innodb_write_io_threads_basic.result | 21 +++ .../sys_vars/r/last_insert_id_basic.result | 20 ++- .../suite/sys_vars/r/lc_messages_basic.result | 8 +- .../sys_vars/r/log_slow_queries_basic.result | 20 +++ .../r/lower_case_file_system_basic.result | 25 ++-- .../r/lower_case_table_names_basic.result | 25 ++-- .../sys_vars/r/max_join_size_basic.result | 14 +- .../sys_vars/r/old_alter_table_basic.result | 14 +- .../sys_vars/r/optimizer_switch_basic.result | 16 ++- .../suite/sys_vars/r/profiling_basic.result | 34 ++++- .../r/profiling_history_size_basic.result | 14 +- .../sys_vars/r/pseudo_thread_id_basic.result | 23 ++-- .../suite/sys_vars/r/rand_seed1_basic.result | 5 + .../suite/sys_vars/r/rand_seed2_basic.result | 5 + .../r/relay_log_recovery_basic.result | 12 ++ .../rpl_semi_sync_master_enabled_basic.result | 73 ++++++++++ .../rpl_semi_sync_master_timeout_basic.result | 54 ++++++++ ..._semi_sync_master_trace_level_basic.result | 72 ++++++++++ ...emi_sync_master_wait_no_slave_basic.result | 73 ++++++++++ .../rpl_semi_sync_slave_enabled_basic.result | 73 ++++++++++ ...l_semi_sync_slave_trace_level_basic.result | 72 ++++++++++ .../sys_vars/r/sql_log_update_basic.result | 42 +++++- .../sys_vars/r/sql_max_join_size_basic.result | 18 ++- .../sys_vars/r/sql_select_limit_basic.result | 14 +- .../sys_vars/r/thread_cache_size_basic.result | 6 + .../suite/sys_vars/t/all_vars-master.opt | 1 + mysql-test/suite/sys_vars/t/all_vars.test | 25 ++++ .../t/innodb_adaptive_flushing_basic.test | 70 ++++++++++ .../t/innodb_adaptive_hash_index_basic.test | 70 ++++++++++ .../t/innodb_change_buffering_basic.test | 59 ++++++++ .../sys_vars/t/innodb_file_format_basic.test | 55 ++++++++ .../t/innodb_file_format_check_basic.test | 55 ++++++++ .../sys_vars/t/innodb_io_capacity_basic.test | 58 ++++++++ .../t/innodb_old_blocks_pct_basic.test | 63 +++++++++ .../t/innodb_old_blocks_time_basic.test | 52 +++++++ .../t/innodb_read_ahead_threshold_basic.test | 60 ++++++++ .../t/innodb_read_io_threads_basic.test | 26 ++++ .../t/innodb_replication_delay_basic.test | 52 +++++++ .../t/innodb_spin_wait_delay_basic.test | 52 +++++++ .../t/innodb_stats_on_metadata_basic.test | 70 ++++++++++ .../t/innodb_stats_sample_pages_basic.test | 52 +++++++ .../sys_vars/t/innodb_strict_mode_basic.test | 84 +++++++++++ .../t/innodb_thread_sleep_delay_basic.test | 52 +++++++ .../t/innodb_use_sys_malloc_basic.test | 28 ++++ .../sys_vars/t/innodb_version_basic.test | 28 ++++ .../t/innodb_write_io_threads_basic.test | 26 ++++ .../sys_vars/t/last_insert_id_basic.test | 14 +- .../suite/sys_vars/t/lc_messages_basic.test | 9 +- .../sys_vars/t/log_slow_queries_basic.test | 18 ++- .../t/lower_case_file_system_basic.test | 24 ++-- .../t/lower_case_table_names_basic.test | 25 ++-- .../suite/sys_vars/t/max_join_size_basic.test | 14 +- .../sys_vars/t/old_alter_table_basic.test | 11 +- .../sys_vars/t/optimizer_switch_basic.test | 13 +- .../suite/sys_vars/t/profiling_basic.test | 19 ++- .../t/profiling_history_size_basic.test | 11 +- .../sys_vars/t/pseudo_thread_id_basic.test | 24 +++- .../suite/sys_vars/t/rand_seed1_basic.test | 6 +- .../suite/sys_vars/t/rand_seed2_basic.test | 7 +- .../sys_vars/t/relay_log_recovery_basic.test | 10 ++ ..._semi_sync_master_enabled_basic-master.opt | 1 + .../t/rpl_semi_sync_master_enabled_basic.test | 62 +++++++++ ..._semi_sync_master_timeout_basic-master.opt | 1 + .../t/rpl_semi_sync_master_timeout_basic.test | 52 +++++++ ...i_sync_master_trace_level_basic-master.opt | 1 + ...pl_semi_sync_master_trace_level_basic.test | 60 ++++++++ ...sync_master_wait_no_slave_basic-master.opt | 1 + ..._semi_sync_master_wait_no_slave_basic.test | 62 +++++++++ ...l_semi_sync_slave_enabled_basic-master.opt | 1 + .../t/rpl_semi_sync_slave_enabled_basic.test | 63 +++++++++ ...mi_sync_slave_trace_level_basic-master.opt | 1 + ...rpl_semi_sync_slave_trace_level_basic.test | 60 ++++++++ .../sys_vars/t/sql_log_update_basic.test | 20 ++- .../sys_vars/t/sql_max_join_size_basic.test | 11 +- .../sys_vars/t/sql_select_limit_basic.test | 11 +- .../sys_vars/t/thread_cache_size_basic.test | 6 + 94 files changed, 3462 insertions(+), 165 deletions(-) create mode 100644 mysql-test/suite/sys_vars/r/innodb_adaptive_flushing_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_adaptive_hash_index_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_change_buffering_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_file_format_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_file_format_check_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_io_capacity_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_old_blocks_pct_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_old_blocks_time_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_read_ahead_threshold_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_read_io_threads_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_replication_delay_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_spin_wait_delay_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_stats_on_metadata_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_stats_sample_pages_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_strict_mode_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_use_sys_malloc_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_version_basic.result create mode 100644 mysql-test/suite/sys_vars/r/innodb_write_io_threads_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_master_enabled_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_master_timeout_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_master_trace_level_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_master_wait_no_slave_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_enabled_basic.result create mode 100644 mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_trace_level_basic.result create mode 100644 mysql-test/suite/sys_vars/t/all_vars-master.opt create mode 100644 mysql-test/suite/sys_vars/t/innodb_adaptive_flushing_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_adaptive_hash_index_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_change_buffering_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_file_format_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_file_format_check_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_io_capacity_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_old_blocks_pct_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_old_blocks_time_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_read_ahead_threshold_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_read_io_threads_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_replication_delay_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_spin_wait_delay_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_stats_on_metadata_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_stats_sample_pages_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_strict_mode_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_thread_sleep_delay_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_use_sys_malloc_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_version_basic.test create mode 100644 mysql-test/suite/sys_vars/t/innodb_write_io_threads_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic-master.opt create mode 100644 mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test diff --git a/mysql-test/suite/sys_vars/r/innodb_adaptive_flushing_basic.result b/mysql-test/suite/sys_vars/r/innodb_adaptive_flushing_basic.result new file mode 100644 index 00000000000..418a693d319 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_adaptive_flushing_basic.result @@ -0,0 +1,92 @@ +SET @start_global_value = @@global.innodb_adaptive_flushing; +SELECT @start_global_value; +@start_global_value +1 +Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_flushing in (0, 1); +@@global.innodb_adaptive_flushing in (0, 1) +1 +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +1 +select @@session.innodb_adaptive_flushing; +ERROR HY000: Variable 'innodb_adaptive_flushing' is a GLOBAL variable +show global variables like 'innodb_adaptive_flushing'; +Variable_name Value +innodb_adaptive_flushing ON +show session variables like 'innodb_adaptive_flushing'; +Variable_name Value +innodb_adaptive_flushing ON +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +set global innodb_adaptive_flushing='OFF'; +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +0 +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING OFF +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING OFF +set @@global.innodb_adaptive_flushing=1; +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +set global innodb_adaptive_flushing=0; +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +0 +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING OFF +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING OFF +set @@global.innodb_adaptive_flushing='ON'; +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +set session innodb_adaptive_flushing='OFF'; +ERROR HY000: Variable 'innodb_adaptive_flushing' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_adaptive_flushing='ON'; +ERROR HY000: Variable 'innodb_adaptive_flushing' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_adaptive_flushing=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_adaptive_flushing' +set global innodb_adaptive_flushing=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_adaptive_flushing' +set global innodb_adaptive_flushing=2; +ERROR 42000: Variable 'innodb_adaptive_flushing' can't be set to the value of '2' +NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_adaptive_flushing=-3; +select @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_FLUSHING ON +set global innodb_adaptive_flushing='AUTO'; +ERROR 42000: Variable 'innodb_adaptive_flushing' can't be set to the value of 'AUTO' +SET @@global.innodb_adaptive_flushing = @start_global_value; +SELECT @@global.innodb_adaptive_flushing; +@@global.innodb_adaptive_flushing +1 diff --git a/mysql-test/suite/sys_vars/r/innodb_adaptive_hash_index_basic.result b/mysql-test/suite/sys_vars/r/innodb_adaptive_hash_index_basic.result new file mode 100644 index 00000000000..bc908090627 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_adaptive_hash_index_basic.result @@ -0,0 +1,92 @@ +SET @start_global_value = @@global.innodb_adaptive_hash_index; +SELECT @start_global_value; +@start_global_value +1 +Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_hash_index in (0, 1); +@@global.innodb_adaptive_hash_index in (0, 1) +1 +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +1 +select @@session.innodb_adaptive_hash_index; +ERROR HY000: Variable 'innodb_adaptive_hash_index' is a GLOBAL variable +show global variables like 'innodb_adaptive_hash_index'; +Variable_name Value +innodb_adaptive_hash_index ON +show session variables like 'innodb_adaptive_hash_index'; +Variable_name Value +innodb_adaptive_hash_index ON +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +set global innodb_adaptive_hash_index='OFF'; +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +0 +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX OFF +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX OFF +set @@global.innodb_adaptive_hash_index=1; +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +set global innodb_adaptive_hash_index=0; +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +0 +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX OFF +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX OFF +set @@global.innodb_adaptive_hash_index='ON'; +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +set session innodb_adaptive_hash_index='OFF'; +ERROR HY000: Variable 'innodb_adaptive_hash_index' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_adaptive_hash_index='ON'; +ERROR HY000: Variable 'innodb_adaptive_hash_index' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_adaptive_hash_index=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_adaptive_hash_index' +set global innodb_adaptive_hash_index=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_adaptive_hash_index' +set global innodb_adaptive_hash_index=2; +ERROR 42000: Variable 'innodb_adaptive_hash_index' can't be set to the value of '2' +NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_adaptive_hash_index=-3; +select @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +1 +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_ADAPTIVE_HASH_INDEX ON +set global innodb_adaptive_hash_index='AUTO'; +ERROR 42000: Variable 'innodb_adaptive_hash_index' can't be set to the value of 'AUTO' +SET @@global.innodb_adaptive_hash_index = @start_global_value; +SELECT @@global.innodb_adaptive_hash_index; +@@global.innodb_adaptive_hash_index +1 diff --git a/mysql-test/suite/sys_vars/r/innodb_change_buffering_basic.result b/mysql-test/suite/sys_vars/r/innodb_change_buffering_basic.result new file mode 100644 index 00000000000..70b0425ce6f --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_change_buffering_basic.result @@ -0,0 +1,63 @@ +SET @start_global_value = @@global.innodb_change_buffering; +SELECT @start_global_value; +@start_global_value +inserts +Valid values are 'inserts' and 'none' +select @@global.innodb_change_buffering in ('inserts', 'none'); +@@global.innodb_change_buffering in ('inserts', 'none') +1 +select @@global.innodb_change_buffering; +@@global.innodb_change_buffering +inserts +select @@session.innodb_change_buffering; +ERROR HY000: Variable 'innodb_change_buffering' is a GLOBAL variable +show global variables like 'innodb_change_buffering'; +Variable_name Value +innodb_change_buffering inserts +show session variables like 'innodb_change_buffering'; +Variable_name Value +innodb_change_buffering inserts +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING inserts +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING inserts +set global innodb_change_buffering='none'; +select @@global.innodb_change_buffering; +@@global.innodb_change_buffering +none +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING none +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING none +set @@global.innodb_change_buffering='inserts'; +select @@global.innodb_change_buffering; +@@global.innodb_change_buffering +inserts +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING inserts +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_CHANGE_BUFFERING inserts +set session innodb_change_buffering='some'; +ERROR HY000: Variable 'innodb_change_buffering' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_change_buffering='some'; +ERROR HY000: Variable 'innodb_change_buffering' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_change_buffering=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_change_buffering' +set global innodb_change_buffering=1; +ERROR 42000: Incorrect argument type to variable 'innodb_change_buffering' +set global innodb_change_buffering=-2; +ERROR 42000: Incorrect argument type to variable 'innodb_change_buffering' +set global innodb_change_buffering=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_change_buffering' +set global innodb_change_buffering='some'; +ERROR 42000: Variable 'innodb_change_buffering' can't be set to the value of 'some' +SET @@global.innodb_change_buffering = @start_global_value; +SELECT @@global.innodb_change_buffering; +@@global.innodb_change_buffering +inserts diff --git a/mysql-test/suite/sys_vars/r/innodb_file_format_basic.result b/mysql-test/suite/sys_vars/r/innodb_file_format_basic.result new file mode 100644 index 00000000000..58e009ea705 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_file_format_basic.result @@ -0,0 +1,59 @@ +SET @start_global_value = @@global.innodb_file_format; +SELECT @start_global_value; +@start_global_value +Antelope +Valid values are 'Antelope' and 'Barracuda' +select @@global.innodb_file_format in ('Antelope', 'Barracuda'); +@@global.innodb_file_format in ('Antelope', 'Barracuda') +1 +select @@global.innodb_file_format; +@@global.innodb_file_format +Antelope +select @@session.innodb_file_format; +ERROR HY000: Variable 'innodb_file_format' is a GLOBAL variable +show global variables like 'innodb_file_format'; +Variable_name Value +innodb_file_format Antelope +show session variables like 'innodb_file_format'; +Variable_name Value +innodb_file_format Antelope +select * from information_schema.global_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Antelope +select * from information_schema.session_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Antelope +set global innodb_file_format='Antelope'; +select @@global.innodb_file_format; +@@global.innodb_file_format +Antelope +select * from information_schema.global_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Antelope +select * from information_schema.session_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Antelope +set @@global.innodb_file_format='Barracuda'; +select @@global.innodb_file_format; +@@global.innodb_file_format +Barracuda +select * from information_schema.global_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Barracuda +select * from information_schema.session_variables where variable_name='innodb_file_format'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT Barracuda +set session innodb_file_format='Salmon'; +ERROR HY000: Variable 'innodb_file_format' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_file_format='Salmon'; +ERROR HY000: Variable 'innodb_file_format' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_file_format=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_file_format' +set global innodb_file_format=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_file_format' +set global innodb_file_format='Salmon'; +ERROR 42000: Variable 'innodb_file_format' can't be set to the value of 'Salmon' +SET @@global.innodb_file_format = @start_global_value; +SELECT @@global.innodb_file_format; +@@global.innodb_file_format +Antelope diff --git a/mysql-test/suite/sys_vars/r/innodb_file_format_check_basic.result b/mysql-test/suite/sys_vars/r/innodb_file_format_check_basic.result new file mode 100644 index 00000000000..29be30cf096 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_file_format_check_basic.result @@ -0,0 +1,59 @@ +SET @start_global_value = @@global.innodb_file_format_check; +SELECT @start_global_value; +@start_global_value +Antelope +Valid values are 'Antelope' and 'Barracuda' +select @@global.innodb_file_format_check in ('Antelope', 'Barracuda'); +@@global.innodb_file_format_check in ('Antelope', 'Barracuda') +1 +select @@global.innodb_file_format_check; +@@global.innodb_file_format_check +Antelope +select @@session.innodb_file_format_check; +ERROR HY000: Variable 'innodb_file_format_check' is a GLOBAL variable +show global variables like 'innodb_file_format_check'; +Variable_name Value +innodb_file_format_check Antelope +show session variables like 'innodb_file_format_check'; +Variable_name Value +innodb_file_format_check Antelope +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Antelope +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Antelope +set global innodb_file_format_check='Antelope'; +select @@global.innodb_file_format_check; +@@global.innodb_file_format_check +Antelope +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Antelope +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Antelope +set @@global.innodb_file_format_check='Barracuda'; +select @@global.innodb_file_format_check; +@@global.innodb_file_format_check +Barracuda +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Barracuda +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_FILE_FORMAT_CHECK Barracuda +set session innodb_file_format_check='Salmon'; +ERROR HY000: Variable 'innodb_file_format_check' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_file_format_check='Salmon'; +ERROR HY000: Variable 'innodb_file_format_check' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_file_format_check=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_file_format_check' +set global innodb_file_format_check=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_file_format_check' +set global innodb_file_format_check='Salmon'; +ERROR 42000: Variable 'innodb_file_format_check' can't be set to the value of 'Salmon' +SET @@global.innodb_file_format_check = @start_global_value; +SELECT @@global.innodb_file_format_check; +@@global.innodb_file_format_check +Antelope diff --git a/mysql-test/suite/sys_vars/r/innodb_io_capacity_basic.result b/mysql-test/suite/sys_vars/r/innodb_io_capacity_basic.result new file mode 100644 index 00000000000..25058bc6f09 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_io_capacity_basic.result @@ -0,0 +1,69 @@ +SET @start_global_value = @@global.innodb_io_capacity; +SELECT @start_global_value; +@start_global_value +200 +Valid value 100 or more +select @@global.innodb_io_capacity > 99; +@@global.innodb_io_capacity > 99 +1 +select @@global.innodb_io_capacity; +@@global.innodb_io_capacity +200 +select @@session.innodb_io_capacity; +ERROR HY000: Variable 'innodb_io_capacity' is a GLOBAL variable +show global variables like 'innodb_io_capacity'; +Variable_name Value +innodb_io_capacity 200 +show session variables like 'innodb_io_capacity'; +Variable_name Value +innodb_io_capacity 200 +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 200 +select * from information_schema.session_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 200 +set global innodb_io_capacity=123; +select @@global.innodb_io_capacity; +@@global.innodb_io_capacity +123 +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 123 +select * from information_schema.session_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 123 +set session innodb_io_capacity=444; +ERROR HY000: Variable 'innodb_io_capacity' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_io_capacity=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_io_capacity' +set global innodb_io_capacity=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_io_capacity' +set global innodb_io_capacity="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_io_capacity' +set global innodb_io_capacity=7; +Warnings: +Warning 1292 Truncated incorrect innodb_io_capacity value: '7' +select @@global.innodb_io_capacity; +@@global.innodb_io_capacity +100 +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 100 +set global innodb_io_capacity=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_io_capacity value: '-7' +select @@global.innodb_io_capacity; +@@global.innodb_io_capacity +100 +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_IO_CAPACITY 100 +set global innodb_io_capacity=100; +select @@global.innodb_io_capacity; +@@global.innodb_io_capacity +100 +SET @@global.innodb_io_capacity = @start_global_value; +SELECT @@global.innodb_io_capacity; +@@global.innodb_io_capacity +200 diff --git a/mysql-test/suite/sys_vars/r/innodb_old_blocks_pct_basic.result b/mysql-test/suite/sys_vars/r/innodb_old_blocks_pct_basic.result new file mode 100644 index 00000000000..bbcc2dabb22 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_old_blocks_pct_basic.result @@ -0,0 +1,82 @@ +SET @start_global_value = @@global.innodb_old_blocks_pct; +SELECT @start_global_value; +@start_global_value +37 +Valid values are between 5 and 95 +select @@global.innodb_old_blocks_pct between 5 and 95; +@@global.innodb_old_blocks_pct between 5 and 95 +1 +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +37 +select @@session.innodb_old_blocks_pct; +ERROR HY000: Variable 'innodb_old_blocks_pct' is a GLOBAL variable +show global variables like 'innodb_old_blocks_pct'; +Variable_name Value +innodb_old_blocks_pct 37 +show session variables like 'innodb_old_blocks_pct'; +Variable_name Value +innodb_old_blocks_pct 37 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 37 +select * from information_schema.session_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 37 +set global innodb_old_blocks_pct=10; +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +10 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 10 +select * from information_schema.session_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 10 +set session innodb_old_blocks_pct=1; +ERROR HY000: Variable 'innodb_old_blocks_pct' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_old_blocks_pct=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_pct' +set global innodb_old_blocks_pct=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_pct' +set global innodb_old_blocks_pct="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_pct' +set global innodb_old_blocks_pct=4; +Warnings: +Warning 1292 Truncated incorrect innodb_old_blocks_pct value: '4' +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +5 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 5 +set global innodb_old_blocks_pct=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_old_blocks_pct value: '-7' +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +5 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 5 +set global innodb_old_blocks_pct=96; +Warnings: +Warning 1292 Truncated incorrect innodb_old_blocks_pct value: '96' +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +95 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_PCT 95 +set global innodb_old_blocks_pct=5; +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +5 +set global innodb_old_blocks_pct=95; +select @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +95 +SET @@global.innodb_old_blocks_pct = @start_global_value; +SELECT @@global.innodb_old_blocks_pct; +@@global.innodb_old_blocks_pct +37 diff --git a/mysql-test/suite/sys_vars/r/innodb_old_blocks_time_basic.result b/mysql-test/suite/sys_vars/r/innodb_old_blocks_time_basic.result new file mode 100644 index 00000000000..a285cc14a01 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_old_blocks_time_basic.result @@ -0,0 +1,56 @@ +SET @start_global_value = @@global.innodb_old_blocks_time; +SELECT @start_global_value; +@start_global_value +0 +Valid values are zero or above +select @@global.innodb_old_blocks_time >=0; +@@global.innodb_old_blocks_time >=0 +1 +select @@global.innodb_old_blocks_time; +@@global.innodb_old_blocks_time +0 +select @@session.innodb_old_blocks_time; +ERROR HY000: Variable 'innodb_old_blocks_time' is a GLOBAL variable +show global variables like 'innodb_old_blocks_time'; +Variable_name Value +innodb_old_blocks_time 0 +show session variables like 'innodb_old_blocks_time'; +Variable_name Value +innodb_old_blocks_time 0 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_TIME 0 +select * from information_schema.session_variables where variable_name='innodb_old_blocks_time'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_TIME 0 +set global innodb_old_blocks_time=10; +select @@global.innodb_old_blocks_time; +@@global.innodb_old_blocks_time +10 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_TIME 10 +select * from information_schema.session_variables where variable_name='innodb_old_blocks_time'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_TIME 10 +set session innodb_old_blocks_time=1; +ERROR HY000: Variable 'innodb_old_blocks_time' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_old_blocks_time=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_time' +set global innodb_old_blocks_time=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_time' +set global innodb_old_blocks_time="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_old_blocks_time' +set global innodb_old_blocks_time=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_old_blocks_time value: '-7' +select @@global.innodb_old_blocks_time; +@@global.innodb_old_blocks_time +0 +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_OLD_BLOCKS_TIME 0 +SET @@global.innodb_old_blocks_time = @start_global_value; +SELECT @@global.innodb_old_blocks_time; +@@global.innodb_old_blocks_time +0 diff --git a/mysql-test/suite/sys_vars/r/innodb_read_ahead_threshold_basic.result b/mysql-test/suite/sys_vars/r/innodb_read_ahead_threshold_basic.result new file mode 100644 index 00000000000..65a1a8e319f --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_read_ahead_threshold_basic.result @@ -0,0 +1,73 @@ +SET @start_global_value = @@global.innodb_read_ahead_threshold; +SELECT @start_global_value; +@start_global_value +56 +Valid values are between 0 and 64 +select @@global.innodb_read_ahead_threshold between 0 and 64; +@@global.innodb_read_ahead_threshold between 0 and 64 +1 +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +56 +select @@session.innodb_read_ahead_threshold; +ERROR HY000: Variable 'innodb_read_ahead_threshold' is a GLOBAL variable +show global variables like 'innodb_read_ahead_threshold'; +Variable_name Value +innodb_read_ahead_threshold 56 +show session variables like 'innodb_read_ahead_threshold'; +Variable_name Value +innodb_read_ahead_threshold 56 +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 56 +select * from information_schema.session_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 56 +set global innodb_read_ahead_threshold=10; +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +10 +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 10 +select * from information_schema.session_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 10 +set session innodb_read_ahead_threshold=1; +ERROR HY000: Variable 'innodb_read_ahead_threshold' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_read_ahead_threshold=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_read_ahead_threshold' +set global innodb_read_ahead_threshold=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_read_ahead_threshold' +set global innodb_read_ahead_threshold="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_read_ahead_threshold' +set global innodb_read_ahead_threshold=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_read_ahead_threshold value: '-7' +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +0 +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 0 +set global innodb_read_ahead_threshold=96; +Warnings: +Warning 1292 Truncated incorrect innodb_read_ahead_threshold value: '96' +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +64 +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_AHEAD_THRESHOLD 64 +set global innodb_read_ahead_threshold=0; +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +0 +set global innodb_read_ahead_threshold=64; +select @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +64 +SET @@global.innodb_read_ahead_threshold = @start_global_value; +SELECT @@global.innodb_read_ahead_threshold; +@@global.innodb_read_ahead_threshold +56 diff --git a/mysql-test/suite/sys_vars/r/innodb_read_io_threads_basic.result b/mysql-test/suite/sys_vars/r/innodb_read_io_threads_basic.result new file mode 100644 index 00000000000..f43fa81c0d0 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_read_io_threads_basic.result @@ -0,0 +1,21 @@ +select @@global.innodb_read_io_threads; +@@global.innodb_read_io_threads +2 +select @@session.innodb_read_io_threads; +ERROR HY000: Variable 'innodb_read_io_threads' is a GLOBAL variable +show global variables like 'innodb_read_io_threads'; +Variable_name Value +innodb_read_io_threads 2 +show session variables like 'innodb_read_io_threads'; +Variable_name Value +innodb_read_io_threads 2 +select * from information_schema.global_variables where variable_name='innodb_read_io_threads'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_IO_THREADS 2 +select * from information_schema.session_variables where variable_name='innodb_read_io_threads'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_READ_IO_THREADS 2 +set global innodb_read_io_threads=1; +ERROR HY000: Variable 'innodb_read_io_threads' is a read only variable +set session innodb_read_io_threads=1; +ERROR HY000: Variable 'innodb_read_io_threads' is a read only variable diff --git a/mysql-test/suite/sys_vars/r/innodb_replication_delay_basic.result b/mysql-test/suite/sys_vars/r/innodb_replication_delay_basic.result new file mode 100644 index 00000000000..fa00baa218e --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_replication_delay_basic.result @@ -0,0 +1,56 @@ +SET @start_global_value = @@global.innodb_replication_delay; +SELECT @start_global_value; +@start_global_value +0 +Valid values are zero or above +select @@global.innodb_replication_delay >=0; +@@global.innodb_replication_delay >=0 +1 +select @@global.innodb_replication_delay; +@@global.innodb_replication_delay +0 +select @@session.innodb_replication_delay; +ERROR HY000: Variable 'innodb_replication_delay' is a GLOBAL variable +show global variables like 'innodb_replication_delay'; +Variable_name Value +innodb_replication_delay 0 +show session variables like 'innodb_replication_delay'; +Variable_name Value +innodb_replication_delay 0 +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_REPLICATION_DELAY 0 +select * from information_schema.session_variables where variable_name='innodb_replication_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_REPLICATION_DELAY 0 +set global innodb_replication_delay=10; +select @@global.innodb_replication_delay; +@@global.innodb_replication_delay +10 +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_REPLICATION_DELAY 10 +select * from information_schema.session_variables where variable_name='innodb_replication_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_REPLICATION_DELAY 10 +set session innodb_replication_delay=1; +ERROR HY000: Variable 'innodb_replication_delay' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_replication_delay=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_replication_delay' +set global innodb_replication_delay=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_replication_delay' +set global innodb_replication_delay="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_replication_delay' +set global innodb_replication_delay=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_replication_delay value: '-7' +select @@global.innodb_replication_delay; +@@global.innodb_replication_delay +0 +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_REPLICATION_DELAY 0 +SET @@global.innodb_replication_delay = @start_global_value; +SELECT @@global.innodb_replication_delay; +@@global.innodb_replication_delay +0 diff --git a/mysql-test/suite/sys_vars/r/innodb_spin_wait_delay_basic.result b/mysql-test/suite/sys_vars/r/innodb_spin_wait_delay_basic.result new file mode 100644 index 00000000000..05672cbb966 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_spin_wait_delay_basic.result @@ -0,0 +1,56 @@ +SET @start_global_value = @@global.innodb_spin_wait_delay; +SELECT @start_global_value; +@start_global_value +6 +Valid values are zero or above +select @@global.innodb_spin_wait_delay >=0; +@@global.innodb_spin_wait_delay >=0 +1 +select @@global.innodb_spin_wait_delay; +@@global.innodb_spin_wait_delay +6 +select @@session.innodb_spin_wait_delay; +ERROR HY000: Variable 'innodb_spin_wait_delay' is a GLOBAL variable +show global variables like 'innodb_spin_wait_delay'; +Variable_name Value +innodb_spin_wait_delay 6 +show session variables like 'innodb_spin_wait_delay'; +Variable_name Value +innodb_spin_wait_delay 6 +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_SPIN_WAIT_DELAY 6 +select * from information_schema.session_variables where variable_name='innodb_spin_wait_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_SPIN_WAIT_DELAY 6 +set global innodb_spin_wait_delay=10; +select @@global.innodb_spin_wait_delay; +@@global.innodb_spin_wait_delay +10 +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_SPIN_WAIT_DELAY 10 +select * from information_schema.session_variables where variable_name='innodb_spin_wait_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_SPIN_WAIT_DELAY 10 +set session innodb_spin_wait_delay=1; +ERROR HY000: Variable 'innodb_spin_wait_delay' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_spin_wait_delay=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_spin_wait_delay' +set global innodb_spin_wait_delay=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_spin_wait_delay' +set global innodb_spin_wait_delay="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_spin_wait_delay' +set global innodb_spin_wait_delay=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_spin_wait_delay value: '-7' +select @@global.innodb_spin_wait_delay; +@@global.innodb_spin_wait_delay +0 +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_SPIN_WAIT_DELAY 0 +SET @@global.innodb_spin_wait_delay = @start_global_value; +SELECT @@global.innodb_spin_wait_delay; +@@global.innodb_spin_wait_delay +6 diff --git a/mysql-test/suite/sys_vars/r/innodb_stats_on_metadata_basic.result b/mysql-test/suite/sys_vars/r/innodb_stats_on_metadata_basic.result new file mode 100644 index 00000000000..d3410d7b9c1 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_stats_on_metadata_basic.result @@ -0,0 +1,92 @@ +SET @start_global_value = @@global.innodb_stats_on_metadata; +SELECT @start_global_value; +@start_global_value +1 +Valid values are 'ON' and 'OFF' +select @@global.innodb_stats_on_metadata in (0, 1); +@@global.innodb_stats_on_metadata in (0, 1) +1 +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +1 +select @@session.innodb_stats_on_metadata; +ERROR HY000: Variable 'innodb_stats_on_metadata' is a GLOBAL variable +show global variables like 'innodb_stats_on_metadata'; +Variable_name Value +innodb_stats_on_metadata ON +show session variables like 'innodb_stats_on_metadata'; +Variable_name Value +innodb_stats_on_metadata ON +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +set global innodb_stats_on_metadata='OFF'; +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +0 +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA OFF +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA OFF +set @@global.innodb_stats_on_metadata=1; +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +1 +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +set global innodb_stats_on_metadata=0; +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +0 +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA OFF +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA OFF +set @@global.innodb_stats_on_metadata='ON'; +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +1 +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +set session innodb_stats_on_metadata='OFF'; +ERROR HY000: Variable 'innodb_stats_on_metadata' is a GLOBAL variable and should be set with SET GLOBAL +set @@session.innodb_stats_on_metadata='ON'; +ERROR HY000: Variable 'innodb_stats_on_metadata' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_stats_on_metadata=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_stats_on_metadata' +set global innodb_stats_on_metadata=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_stats_on_metadata' +set global innodb_stats_on_metadata=2; +ERROR 42000: Variable 'innodb_stats_on_metadata' can't be set to the value of '2' +NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_stats_on_metadata=-3; +select @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +1 +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_ON_METADATA ON +set global innodb_stats_on_metadata='AUTO'; +ERROR 42000: Variable 'innodb_stats_on_metadata' can't be set to the value of 'AUTO' +SET @@global.innodb_stats_on_metadata = @start_global_value; +SELECT @@global.innodb_stats_on_metadata; +@@global.innodb_stats_on_metadata +1 diff --git a/mysql-test/suite/sys_vars/r/innodb_stats_sample_pages_basic.result b/mysql-test/suite/sys_vars/r/innodb_stats_sample_pages_basic.result new file mode 100644 index 00000000000..153ae95a4fe --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_stats_sample_pages_basic.result @@ -0,0 +1,56 @@ +SET @start_global_value = @@global.innodb_stats_sample_pages; +SELECT @start_global_value; +@start_global_value +8 +Valid values are one or above +select @@global.innodb_stats_sample_pages >=1; +@@global.innodb_stats_sample_pages >=1 +1 +select @@global.innodb_stats_sample_pages; +@@global.innodb_stats_sample_pages +8 +select @@session.innodb_stats_sample_pages; +ERROR HY000: Variable 'innodb_stats_sample_pages' is a GLOBAL variable +show global variables like 'innodb_stats_sample_pages'; +Variable_name Value +innodb_stats_sample_pages 8 +show session variables like 'innodb_stats_sample_pages'; +Variable_name Value +innodb_stats_sample_pages 8 +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_SAMPLE_PAGES 8 +select * from information_schema.session_variables where variable_name='innodb_stats_sample_pages'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_SAMPLE_PAGES 8 +set global innodb_stats_sample_pages=10; +select @@global.innodb_stats_sample_pages; +@@global.innodb_stats_sample_pages +10 +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_SAMPLE_PAGES 10 +select * from information_schema.session_variables where variable_name='innodb_stats_sample_pages'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_SAMPLE_PAGES 10 +set session innodb_stats_sample_pages=1; +ERROR HY000: Variable 'innodb_stats_sample_pages' is a GLOBAL variable and should be set with SET GLOBAL +set global innodb_stats_sample_pages=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_stats_sample_pages' +set global innodb_stats_sample_pages=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_stats_sample_pages' +set global innodb_stats_sample_pages="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_stats_sample_pages' +set global innodb_stats_sample_pages=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_stats_sample_pages value: '-7' +select @@global.innodb_stats_sample_pages; +@@global.innodb_stats_sample_pages +1 +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STATS_SAMPLE_PAGES 1 +SET @@global.innodb_stats_sample_pages = @start_global_value; +SELECT @@global.innodb_stats_sample_pages; +@@global.innodb_stats_sample_pages +8 diff --git a/mysql-test/suite/sys_vars/r/innodb_strict_mode_basic.result b/mysql-test/suite/sys_vars/r/innodb_strict_mode_basic.result new file mode 100644 index 00000000000..200f9166215 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_strict_mode_basic.result @@ -0,0 +1,120 @@ +SET @start_global_value = @@global.innodb_strict_mode; +SELECT @start_global_value; +@start_global_value +0 +Valid values are 'ON' and 'OFF' +select @@global.innodb_strict_mode in (0, 1); +@@global.innodb_strict_mode in (0, 1) +1 +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +0 +select @@session.innodb_strict_mode in (0, 1); +@@session.innodb_strict_mode in (0, 1) +1 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +0 +show global variables like 'innodb_strict_mode'; +Variable_name Value +innodb_strict_mode OFF +show session variables like 'innodb_strict_mode'; +Variable_name Value +innodb_strict_mode OFF +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +set global innodb_strict_mode='OFF'; +set session innodb_strict_mode='OFF'; +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +0 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +0 +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +set @@global.innodb_strict_mode=1; +set @@session.innodb_strict_mode=1; +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +1 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +1 +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +set global innodb_strict_mode=0; +set session innodb_strict_mode=0; +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +0 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +0 +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE OFF +set @@global.innodb_strict_mode='ON'; +set @@session.innodb_strict_mode='ON'; +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +1 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +1 +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +set global innodb_strict_mode=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_strict_mode' +set session innodb_strict_mode=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_strict_mode' +set global innodb_strict_mode=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_strict_mode' +set session innodb_strict_mode=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_strict_mode' +set global innodb_strict_mode=2; +ERROR 42000: Variable 'innodb_strict_mode' can't be set to the value of '2' +set session innodb_strict_mode=2; +ERROR 42000: Variable 'innodb_strict_mode' can't be set to the value of '2' +set global innodb_strict_mode='AUTO'; +ERROR 42000: Variable 'innodb_strict_mode' can't be set to the value of 'AUTO' +set session innodb_strict_mode='AUTO'; +ERROR 42000: Variable 'innodb_strict_mode' can't be set to the value of 'AUTO' +NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_strict_mode=-3; +set session innodb_strict_mode=-7; +select @@global.innodb_strict_mode; +@@global.innodb_strict_mode +1 +select @@session.innodb_strict_mode; +@@session.innodb_strict_mode +1 +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_STRICT_MODE ON +SET @@global.innodb_strict_mode = @start_global_value; +SELECT @@global.innodb_strict_mode; +@@global.innodb_strict_mode +0 diff --git a/mysql-test/suite/sys_vars/r/innodb_thread_sleep_delay_basic.result b/mysql-test/suite/sys_vars/r/innodb_thread_sleep_delay_basic.result index 979bfd930ca..fb7093ec3b3 100644 --- a/mysql-test/suite/sys_vars/r/innodb_thread_sleep_delay_basic.result +++ b/mysql-test/suite/sys_vars/r/innodb_thread_sleep_delay_basic.result @@ -1,84 +1,56 @@ -SET @global_start_value = @@global.innodb_thread_sleep_delay; -SELECT @global_start_value; -@global_start_value +SET @start_global_value = @@global.innodb_thread_sleep_delay; +SELECT @start_global_value; +@start_global_value 10000 -'#--------------------FN_DYNVARS_046_01------------------------#' -SET @@global.innodb_thread_sleep_delay = 0; -SET @@global.innodb_thread_sleep_delay = DEFAULT; -SELECT @@global.innodb_thread_sleep_delay; +Valid values are zero or above +select @@global.innodb_thread_sleep_delay >=0; +@@global.innodb_thread_sleep_delay >=0 +1 +select @@global.innodb_thread_sleep_delay; @@global.innodb_thread_sleep_delay 10000 -'#---------------------FN_DYNVARS_046_02-------------------------#' -SET innodb_thread_sleep_delay = 1; +select @@session.innodb_thread_sleep_delay; +ERROR HY000: Variable 'innodb_thread_sleep_delay' is a GLOBAL variable +show global variables like 'innodb_thread_sleep_delay'; +Variable_name Value +innodb_thread_sleep_delay 10000 +show session variables like 'innodb_thread_sleep_delay'; +Variable_name Value +innodb_thread_sleep_delay 10000 +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_THREAD_SLEEP_DELAY 10000 +select * from information_schema.session_variables where variable_name='innodb_thread_sleep_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_THREAD_SLEEP_DELAY 10000 +set global innodb_thread_sleep_delay=10; +select @@global.innodb_thread_sleep_delay; +@@global.innodb_thread_sleep_delay +10 +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_THREAD_SLEEP_DELAY 10 +select * from information_schema.session_variables where variable_name='innodb_thread_sleep_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_THREAD_SLEEP_DELAY 10 +set session innodb_thread_sleep_delay=1; ERROR HY000: Variable 'innodb_thread_sleep_delay' is a GLOBAL variable and should be set with SET GLOBAL -SELECT @@innodb_thread_sleep_delay; -@@innodb_thread_sleep_delay +set global innodb_thread_sleep_delay=1.1; +ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' +set global innodb_thread_sleep_delay=1e1; +ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' +set global innodb_thread_sleep_delay="foo"; +ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' +set global innodb_thread_sleep_delay=-7; +Warnings: +Warning 1292 Truncated incorrect innodb_thread_sleep_delay value: '-7' +select @@global.innodb_thread_sleep_delay; +@@global.innodb_thread_sleep_delay +0 +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_THREAD_SLEEP_DELAY 0 +SET @@global.innodb_thread_sleep_delay = @start_global_value; +SELECT @@global.innodb_thread_sleep_delay; +@@global.innodb_thread_sleep_delay 10000 -SELECT local.innodb_thread_sleep_delay; -ERROR 42S02: Unknown table 'local' in field list -SET global innodb_thread_sleep_delay = 0; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -0 -'#--------------------FN_DYNVARS_046_03------------------------#' -SET @@global.innodb_thread_sleep_delay = 0; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -0 -SET @@global.innodb_thread_sleep_delay = 1; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -1 -SET @@global.innodb_thread_sleep_delay = 4294967295; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -4294967295 -'#--------------------FN_DYNVARS_046_04-------------------------#' -SET @@global.innodb_thread_sleep_delay = -1; -SELECT @@global.innodb_autoextend_increment; -@@global.innodb_autoextend_increment -8 -SET @@global.innodb_thread_sleep_delay = "T"; -ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' -SELECT @@global.innodb_autoextend_increment; -@@global.innodb_autoextend_increment -8 -SET @@global.innodb_thread_sleep_delay = "Y"; -ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' -SELECT @@global.innodb_autoextend_increment; -@@global.innodb_autoextend_increment -8 -SET @@global.innodb_thread_sleep_delay = 1001; -SELECT @@global.innodb_autoextend_increment; -@@global.innodb_autoextend_increment -8 -'#----------------------FN_DYNVARS_046_05------------------------#' -SELECT @@global.innodb_thread_sleep_delay = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='innodb_thread_sleep_delay'; -@@global.innodb_thread_sleep_delay = VARIABLE_VALUE -1 -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -1001 -SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='innodb_thread_sleep_delay'; -VARIABLE_VALUE -1001 -'#---------------------FN_DYNVARS_046_06-------------------------#' -SET @@global.innodb_thread_sleep_delay = OFF; -ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -1001 -SET @@global.innodb_thread_sleep_delay = ON; -ERROR 42000: Incorrect argument type to variable 'innodb_thread_sleep_delay' -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -1001 -'#---------------------FN_DYNVARS_046_07----------------------#' -SET @@global.innodb_thread_sleep_delay = TRUE; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -1 -SET @@global.innodb_thread_sleep_delay = FALSE; -SELECT @@global.innodb_thread_sleep_delay; -@@global.innodb_thread_sleep_delay -0 diff --git a/mysql-test/suite/sys_vars/r/innodb_use_sys_malloc_basic.result b/mysql-test/suite/sys_vars/r/innodb_use_sys_malloc_basic.result new file mode 100644 index 00000000000..0c2685b1a49 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_use_sys_malloc_basic.result @@ -0,0 +1,25 @@ +Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_flushing in (0, 1); +@@global.innodb_adaptive_flushing in (0, 1) +1 +select @@global.innodb_use_sys_malloc; +@@global.innodb_use_sys_malloc +1 +select @@session.innodb_use_sys_malloc; +ERROR HY000: Variable 'innodb_use_sys_malloc' is a GLOBAL variable +show global variables like 'innodb_use_sys_malloc'; +Variable_name Value +innodb_use_sys_malloc ON +show session variables like 'innodb_use_sys_malloc'; +Variable_name Value +innodb_use_sys_malloc ON +select * from information_schema.global_variables where variable_name='innodb_use_sys_malloc'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_USE_SYS_MALLOC ON +select * from information_schema.session_variables where variable_name='innodb_use_sys_malloc'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_USE_SYS_MALLOC ON +set global innodb_use_sys_malloc=1; +ERROR HY000: Variable 'innodb_use_sys_malloc' is a read only variable +set session innodb_use_sys_malloc=1; +ERROR HY000: Variable 'innodb_use_sys_malloc' is a read only variable diff --git a/mysql-test/suite/sys_vars/r/innodb_version_basic.result b/mysql-test/suite/sys_vars/r/innodb_version_basic.result new file mode 100644 index 00000000000..759b5048512 --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_version_basic.result @@ -0,0 +1,17 @@ +select @@global.innodb_version; +@@global.innodb_version +x.y.z +select @@session.innodb_version; +ERROR HY000: Variable 'innodb_version' is a GLOBAL variable +show global variables like 'innodb_version' disabled so to not change with every version; +show session variables like 'innodb_version' disabled so to not change with every version; +select VARIABLE_VALUE=@@global.innodb_version from information_schema.global_variables where variable_name='innodb_version'; +VARIABLE_VALUE=@@global.innodb_version +1 +select VARIABLE_VALUE=@@global.innodb_version from information_schema.session_variables where variable_name='innodb_version'; +VARIABLE_VALUE=@@global.innodb_version +1 +set global innodb_version=1; +ERROR HY000: Variable 'innodb_version' is a read only variable +set session innodb_version=1; +ERROR HY000: Variable 'innodb_version' is a read only variable diff --git a/mysql-test/suite/sys_vars/r/innodb_write_io_threads_basic.result b/mysql-test/suite/sys_vars/r/innodb_write_io_threads_basic.result new file mode 100644 index 00000000000..a363f4292dd --- /dev/null +++ b/mysql-test/suite/sys_vars/r/innodb_write_io_threads_basic.result @@ -0,0 +1,21 @@ +select @@global.innodb_write_io_threads; +@@global.innodb_write_io_threads +2 +select @@session.innodb_write_io_threads; +ERROR HY000: Variable 'innodb_write_io_threads' is a GLOBAL variable +show global variables like 'innodb_write_io_threads'; +Variable_name Value +innodb_write_io_threads 2 +show session variables like 'innodb_write_io_threads'; +Variable_name Value +innodb_write_io_threads 2 +select * from information_schema.global_variables where variable_name='innodb_write_io_threads'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_WRITE_IO_THREADS 2 +select * from information_schema.session_variables where variable_name='innodb_write_io_threads'; +VARIABLE_NAME VARIABLE_VALUE +INNODB_WRITE_IO_THREADS 2 +set global innodb_write_io_threads=1; +ERROR HY000: Variable 'innodb_write_io_threads' is a read only variable +set session innodb_write_io_threads=1; +ERROR HY000: Variable 'innodb_write_io_threads' is a read only variable diff --git a/mysql-test/suite/sys_vars/r/last_insert_id_basic.result b/mysql-test/suite/sys_vars/r/last_insert_id_basic.result index c29a313b9e7..a4ae20dbabb 100644 --- a/mysql-test/suite/sys_vars/r/last_insert_id_basic.result +++ b/mysql-test/suite/sys_vars/r/last_insert_id_basic.result @@ -13,12 +13,24 @@ VARIABLE_NAME VARIABLE_VALUE select * from information_schema.session_variables where variable_name='last_insert_id'; VARIABLE_NAME VARIABLE_VALUE LAST_INSERT_ID 0 -set session last_insert_id=1; +set global last_insert_id=99; +ERROR HY000: Variable 'last_insert_id' is a SESSION variable and can't be used with SET GLOBAL +set session last_insert_id=42; +select @@global.last_insert_id; +ERROR HY000: Variable 'last_insert_id' is a SESSION variable select @@session.last_insert_id; @@session.last_insert_id -1 -set global last_insert_id=1; -ERROR HY000: Variable 'last_insert_id' is a SESSION variable and can't be used with SET GLOBAL +42 +show global variables like 'last_insert_id'; +Variable_name Value +show session variables like 'last_insert_id'; +Variable_name Value +last_insert_id 42 +select * from information_schema.global_variables where variable_name='last_insert_id'; +VARIABLE_NAME VARIABLE_VALUE +select * from information_schema.session_variables where variable_name='last_insert_id'; +VARIABLE_NAME VARIABLE_VALUE +LAST_INSERT_ID 42 set session last_insert_id=1.1; ERROR 42000: Incorrect argument type to variable 'last_insert_id' set session last_insert_id=1e1; diff --git a/mysql-test/suite/sys_vars/r/lc_messages_basic.result b/mysql-test/suite/sys_vars/r/lc_messages_basic.result index e765dd53516..b9350828dba 100644 --- a/mysql-test/suite/sys_vars/r/lc_messages_basic.result +++ b/mysql-test/suite/sys_vars/r/lc_messages_basic.result @@ -29,13 +29,19 @@ select @@session.lc_messages; @@session.lc_messages ja_JP set global lc_messages="en_US"; +set session lc_messages="en_GB"; select @@global.lc_messages; @@global.lc_messages en_US -set session lc_messages="en_GB"; select @@session.lc_messages; @@session.lc_messages en_GB +select * from information_schema.global_variables where variable_name='lc_messages'; +VARIABLE_NAME VARIABLE_VALUE +LC_MESSAGES en_US +select * from information_schema.session_variables where variable_name='lc_messages'; +VARIABLE_NAME VARIABLE_VALUE +LC_MESSAGES en_GB set global lc_messages=1.1; ERROR 42000: Incorrect argument type to variable 'lc_messages' set global lc_messages=1e1; diff --git a/mysql-test/suite/sys_vars/r/log_slow_queries_basic.result b/mysql-test/suite/sys_vars/r/log_slow_queries_basic.result index ca530ebb41a..1748406b74b 100644 --- a/mysql-test/suite/sys_vars/r/log_slow_queries_basic.result +++ b/mysql-test/suite/sys_vars/r/log_slow_queries_basic.result @@ -65,12 +65,22 @@ Warning 1287 The syntax '@@log_slow_queries' is deprecated and will be removed i SELECT @@global.log_slow_queries; @@global.log_slow_queries 0 +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; +IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +1 SET @@global.log_slow_queries = 1; Warnings: Warning 1287 The syntax '@@log_slow_queries' is deprecated and will be removed in MySQL 7.0. Please use '@@slow_query_log' instead SELECT @@global.log_slow_queries; @@global.log_slow_queries 1 +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; +IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +1 '#---------------------FN_DYNVARS_004_07----------------------#' SET @@global.log_slow_queries = TRUE; Warnings: @@ -78,12 +88,22 @@ Warning 1287 The syntax '@@log_slow_queries' is deprecated and will be removed i SELECT @@global.log_slow_queries; @@global.log_slow_queries 1 +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; +IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +1 SET @@global.log_slow_queries = FALSE; Warnings: Warning 1287 The syntax '@@log_slow_queries' is deprecated and will be removed in MySQL 7.0. Please use '@@slow_query_log' instead SELECT @@global.log_slow_queries; @@global.log_slow_queries 0 +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; +IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +1 '#---------------------FN_DYNVARS_004_08----------------------#' SET @@global.log_slow_queries = ON; Warnings: diff --git a/mysql-test/suite/sys_vars/r/lower_case_file_system_basic.result b/mysql-test/suite/sys_vars/r/lower_case_file_system_basic.result index 0488ed30dc0..4ecd81685c5 100644 --- a/mysql-test/suite/sys_vars/r/lower_case_file_system_basic.result +++ b/mysql-test/suite/sys_vars/r/lower_case_file_system_basic.result @@ -3,18 +3,19 @@ select @@global.lower_case_file_system=2; 0 select @@session.lower_case_file_system; ERROR HY000: Variable 'lower_case_file_system' is a GLOBAL variable -show global variables like 'lower_case_file_system'; -Variable_name Value -lower_case_file_system # -show session variables like 'lower_case_file_system'; -Variable_name Value -lower_case_file_system # -select * from information_schema.global_variables where variable_name='lower_case_file_system'; -VARIABLE_NAME VARIABLE_VALUE -LOWER_CASE_FILE_SYSTEM # -select * from information_schema.session_variables where variable_name='lower_case_file_system'; -VARIABLE_NAME VARIABLE_VALUE -LOWER_CASE_FILE_SYSTEM # +SELECT @@global.lower_case_file_system in (0,1); +@@global.lower_case_file_system in (0,1) +1 +SELECT IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_file_system'; +IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +1 +SELECT IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='lower_case_file_system'; +IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +1 set global lower_case_file_system=1; ERROR HY000: Variable 'lower_case_file_system' is a read only variable set session lower_case_file_system=1; diff --git a/mysql-test/suite/sys_vars/r/lower_case_table_names_basic.result b/mysql-test/suite/sys_vars/r/lower_case_table_names_basic.result index d7dc6d69e30..cae6ecb215c 100644 --- a/mysql-test/suite/sys_vars/r/lower_case_table_names_basic.result +++ b/mysql-test/suite/sys_vars/r/lower_case_table_names_basic.result @@ -3,18 +3,19 @@ select @@global.lower_case_table_names=20; 0 select @@session.lower_case_table_names; ERROR HY000: Variable 'lower_case_table_names' is a GLOBAL variable -show global variables like 'lower_case_table_names'; -Variable_name Value -lower_case_table_names # -show session variables like 'lower_case_table_names'; -Variable_name Value -lower_case_table_names # -select * from information_schema.global_variables where variable_name='lower_case_table_names'; -VARIABLE_NAME VARIABLE_VALUE -LOWER_CASE_TABLE_NAMES # -select * from information_schema.session_variables where variable_name='lower_case_table_names'; -VARIABLE_NAME VARIABLE_VALUE -LOWER_CASE_TABLE_NAMES # +SELECT @@global.lower_case_table_names in (0,1,2); +@@global.lower_case_table_names in (0,1,2) +1 +SELECT @@global.lower_case_table_names = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_table_names'; +@@global.lower_case_table_names = VARIABLE_VALUE +1 +SELECT @@global.lower_case_table_names = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_table_names'; +@@global.lower_case_table_names = VARIABLE_VALUE +1 set global lower_case_table_names=1; ERROR HY000: Variable 'lower_case_table_names' is a read only variable set session lower_case_table_names=1; diff --git a/mysql-test/suite/sys_vars/r/max_join_size_basic.result b/mysql-test/suite/sys_vars/r/max_join_size_basic.result index 5cebefe9ea3..acf9f123238 100644 --- a/mysql-test/suite/sys_vars/r/max_join_size_basic.result +++ b/mysql-test/suite/sys_vars/r/max_join_size_basic.result @@ -21,13 +21,25 @@ select * from information_schema.session_variables where variable_name='max_join VARIABLE_NAME VARIABLE_VALUE MAX_JOIN_SIZE 18446744073709551615 set global max_join_size=10; +set session max_join_size=20; select @@global.max_join_size; @@global.max_join_size 10 -set session max_join_size=20; select @@session.max_join_size; @@session.max_join_size 20 +show global variables like 'max_join_size'; +Variable_name Value +max_join_size 10 +show session variables like 'max_join_size'; +Variable_name Value +max_join_size 20 +select * from information_schema.global_variables where variable_name='max_join_size'; +VARIABLE_NAME VARIABLE_VALUE +MAX_JOIN_SIZE 10 +select * from information_schema.session_variables where variable_name='max_join_size'; +VARIABLE_NAME VARIABLE_VALUE +MAX_JOIN_SIZE 20 set global max_join_size=1.1; ERROR 42000: Incorrect argument type to variable 'max_join_size' set global max_join_size=1e1; diff --git a/mysql-test/suite/sys_vars/r/old_alter_table_basic.result b/mysql-test/suite/sys_vars/r/old_alter_table_basic.result index 0619235b8e0..5cc17917242 100644 --- a/mysql-test/suite/sys_vars/r/old_alter_table_basic.result +++ b/mysql-test/suite/sys_vars/r/old_alter_table_basic.result @@ -21,13 +21,25 @@ select * from information_schema.session_variables where variable_name='old_alte VARIABLE_NAME VARIABLE_VALUE OLD_ALTER_TABLE OFF set global old_alter_table=1; +set session old_alter_table=ON; select @@global.old_alter_table; @@global.old_alter_table 1 -set session old_alter_table=ON; select @@session.old_alter_table; @@session.old_alter_table 1 +show global variables like 'old_alter_table'; +Variable_name Value +old_alter_table ON +show session variables like 'old_alter_table'; +Variable_name Value +old_alter_table ON +select * from information_schema.global_variables where variable_name='old_alter_table'; +VARIABLE_NAME VARIABLE_VALUE +OLD_ALTER_TABLE ON +select * from information_schema.session_variables where variable_name='old_alter_table'; +VARIABLE_NAME VARIABLE_VALUE +OLD_ALTER_TABLE ON set global old_alter_table=1.1; ERROR 42000: Incorrect argument type to variable 'old_alter_table' set global old_alter_table=1e1; diff --git a/mysql-test/suite/sys_vars/r/optimizer_switch_basic.result b/mysql-test/suite/sys_vars/r/optimizer_switch_basic.result index 2d648259a26..acc8cd699f8 100644 --- a/mysql-test/suite/sys_vars/r/optimizer_switch_basic.result +++ b/mysql-test/suite/sys_vars/r/optimizer_switch_basic.result @@ -21,21 +21,33 @@ select * from information_schema.session_variables where variable_name='optimize VARIABLE_NAME VARIABLE_VALUE OPTIMIZER_SWITCH index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on set global optimizer_switch=10; +set session optimizer_switch=5; select @@global.optimizer_switch; @@global.optimizer_switch index_merge=off,index_merge_union=on,index_merge_sort_union=off,index_merge_intersection=on,engine_condition_pushdown=off -set session optimizer_switch=5; select @@session.optimizer_switch; @@session.optimizer_switch index_merge=on,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=off,engine_condition_pushdown=off set global optimizer_switch="index_merge_sort_union=on"; +set session optimizer_switch="index_merge=off"; select @@global.optimizer_switch; @@global.optimizer_switch index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=off -set session optimizer_switch="index_merge=off"; select @@session.optimizer_switch; @@session.optimizer_switch index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=off,engine_condition_pushdown=off +show global variables like 'optimizer_switch'; +Variable_name Value +optimizer_switch index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=off +show session variables like 'optimizer_switch'; +Variable_name Value +optimizer_switch index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=off,engine_condition_pushdown=off +select * from information_schema.global_variables where variable_name='optimizer_switch'; +VARIABLE_NAME VARIABLE_VALUE +OPTIMIZER_SWITCH index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=off +select * from information_schema.session_variables where variable_name='optimizer_switch'; +VARIABLE_NAME VARIABLE_VALUE +OPTIMIZER_SWITCH index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=off,engine_condition_pushdown=off set session optimizer_switch="default"; select @@session.optimizer_switch; @@session.optimizer_switch diff --git a/mysql-test/suite/sys_vars/r/profiling_basic.result b/mysql-test/suite/sys_vars/r/profiling_basic.result index 26704b6b725..4f987d690ba 100644 --- a/mysql-test/suite/sys_vars/r/profiling_basic.result +++ b/mysql-test/suite/sys_vars/r/profiling_basic.result @@ -21,13 +21,45 @@ select * from information_schema.session_variables where variable_name='profilin VARIABLE_NAME VARIABLE_VALUE PROFILING OFF set global profiling=1; +set session profiling=ON; select @@global.profiling; @@global.profiling 1 -set session profiling=ON; select @@session.profiling; @@session.profiling 1 +show global variables like 'profiling'; +Variable_name Value +profiling ON +show session variables like 'profiling'; +Variable_name Value +profiling ON +select * from information_schema.global_variables where variable_name='profiling'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING ON +select * from information_schema.session_variables where variable_name='profiling'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING ON +set global profiling=0; +set session profiling=OFF; +select @@global.profiling; +@@global.profiling +0 +select @@session.profiling; +@@session.profiling +0 +show global variables like 'profiling'; +Variable_name Value +profiling OFF +show session variables like 'profiling'; +Variable_name Value +profiling OFF +select * from information_schema.global_variables where variable_name='profiling'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING OFF +select * from information_schema.session_variables where variable_name='profiling'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING OFF set global profiling=1.1; ERROR 42000: Incorrect argument type to variable 'profiling' set global profiling=1e1; diff --git a/mysql-test/suite/sys_vars/r/profiling_history_size_basic.result b/mysql-test/suite/sys_vars/r/profiling_history_size_basic.result index be92d075326..396d280ad18 100644 --- a/mysql-test/suite/sys_vars/r/profiling_history_size_basic.result +++ b/mysql-test/suite/sys_vars/r/profiling_history_size_basic.result @@ -21,13 +21,25 @@ select * from information_schema.session_variables where variable_name='profilin VARIABLE_NAME VARIABLE_VALUE PROFILING_HISTORY_SIZE 15 set global profiling_history_size=10; +set session profiling_history_size=20; select @@global.profiling_history_size; @@global.profiling_history_size 10 -set session profiling_history_size=20; select @@session.profiling_history_size; @@session.profiling_history_size 20 +show global variables like 'profiling_history_size'; +Variable_name Value +profiling_history_size 10 +show session variables like 'profiling_history_size'; +Variable_name Value +profiling_history_size 20 +select * from information_schema.global_variables where variable_name='profiling_history_size'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING_HISTORY_SIZE 10 +select * from information_schema.session_variables where variable_name='profiling_history_size'; +VARIABLE_NAME VARIABLE_VALUE +PROFILING_HISTORY_SIZE 20 set global profiling_history_size=1.1; ERROR 42000: Incorrect argument type to variable 'profiling_history_size' set global profiling_history_size=1e1; diff --git a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result index e6619e206f1..6b0a8899560 100644 --- a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result +++ b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result @@ -1,22 +1,29 @@ select @@global.pseudo_thread_id; ERROR HY000: Variable 'pseudo_thread_id' is a SESSION variable -select @@session.pseudo_thread_id=0; -@@session.pseudo_thread_id=0 -0 +select @@session.pseudo_thread_id between 1 and 1000; +@@session.pseudo_thread_id between 1 and 1000 +1 +should be empty show global variables like 'pseudo_thread_id'; Variable_name Value show session variables like 'pseudo_thread_id'; Variable_name Value pseudo_thread_id # +should be empty select * from information_schema.global_variables where variable_name='pseudo_thread_id'; VARIABLE_NAME VARIABLE_VALUE -select * from information_schema.session_variables where variable_name='pseudo_thread_id'; -VARIABLE_NAME VARIABLE_VALUE -PSEUDO_THREAD_ID # -set session pseudo_thread_id=1; +select @@session.pseudo_thread_id = variable_value from information_schema.session_variables where variable_name='pseudo_thread_id'; +@@session.pseudo_thread_id = variable_value +1 +set session pseudo_thread_id=42; select @@session.pseudo_thread_id; @@session.pseudo_thread_id -1 +42 +select * from information_schema.global_variables where variable_name='pseudo_thread_id'; +VARIABLE_NAME VARIABLE_VALUE +select variable_value from information_schema.session_variables where variable_name='pseudo_thread_id'; +variable_value +42 set global pseudo_thread_id=1; ERROR HY000: Variable 'pseudo_thread_id' is a SESSION variable and can't be used with SET GLOBAL set session pseudo_thread_id=1.1; diff --git a/mysql-test/suite/sys_vars/r/rand_seed1_basic.result b/mysql-test/suite/sys_vars/r/rand_seed1_basic.result index 7b92d533c9e..155d7169168 100644 --- a/mysql-test/suite/sys_vars/r/rand_seed1_basic.result +++ b/mysql-test/suite/sys_vars/r/rand_seed1_basic.result @@ -17,6 +17,11 @@ set session rand_seed1=1; select @@session.rand_seed1; @@session.rand_seed1 0 +select * from information_schema.global_variables where variable_name='rand_seed1'; +VARIABLE_NAME VARIABLE_VALUE +select * from information_schema.session_variables where variable_name='rand_seed1'; +VARIABLE_NAME VARIABLE_VALUE +RAND_SEED1 0 set global rand_seed1=1; ERROR HY000: Variable 'rand_seed1' is a SESSION variable and can't be used with SET GLOBAL set session rand_seed1=1.1; diff --git a/mysql-test/suite/sys_vars/r/rand_seed2_basic.result b/mysql-test/suite/sys_vars/r/rand_seed2_basic.result index 3d84aa3e37e..4974d8a53a3 100644 --- a/mysql-test/suite/sys_vars/r/rand_seed2_basic.result +++ b/mysql-test/suite/sys_vars/r/rand_seed2_basic.result @@ -17,6 +17,11 @@ set session rand_seed2=1; select @@session.rand_seed2; @@session.rand_seed2 0 +select * from information_schema.global_variables where variable_name='rand_seed2'; +VARIABLE_NAME VARIABLE_VALUE +select * from information_schema.session_variables where variable_name='rand_seed2'; +VARIABLE_NAME VARIABLE_VALUE +RAND_SEED2 0 set global rand_seed2=1; ERROR HY000: Variable 'rand_seed2' is a SESSION variable and can't be used with SET GLOBAL set session rand_seed2=1.1; diff --git a/mysql-test/suite/sys_vars/r/relay_log_recovery_basic.result b/mysql-test/suite/sys_vars/r/relay_log_recovery_basic.result index 97b991ce65b..af3b51bcffe 100644 --- a/mysql-test/suite/sys_vars/r/relay_log_recovery_basic.result +++ b/mysql-test/suite/sys_vars/r/relay_log_recovery_basic.result @@ -23,10 +23,22 @@ set global relay_log_recovery=1; select @@global.relay_log_recovery; @@global.relay_log_recovery 1 +select * from information_schema.global_variables where variable_name='relay_log_recovery'; +VARIABLE_NAME VARIABLE_VALUE +RELAY_LOG_RECOVERY ON +select * from information_schema.session_variables where variable_name='relay_log_recovery'; +VARIABLE_NAME VARIABLE_VALUE +RELAY_LOG_RECOVERY ON set global relay_log_recovery=OFF; select @@global.relay_log_recovery; @@global.relay_log_recovery 0 +select * from information_schema.global_variables where variable_name='relay_log_recovery'; +VARIABLE_NAME VARIABLE_VALUE +RELAY_LOG_RECOVERY OFF +select * from information_schema.session_variables where variable_name='relay_log_recovery'; +VARIABLE_NAME VARIABLE_VALUE +RELAY_LOG_RECOVERY OFF set session relay_log_recovery=1; ERROR HY000: Variable 'relay_log_recovery' is a GLOBAL variable and should be set with SET GLOBAL set global relay_log_recovery=1.1; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_enabled_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_enabled_basic.result new file mode 100644 index 00000000000..ad3ca0de0fa --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_enabled_basic.result @@ -0,0 +1,73 @@ +INSTALL PLUGIN rpl_semi_sync_master SONAME 'semisync_master.so'; +select @@global.rpl_semi_sync_master_enabled; +@@global.rpl_semi_sync_master_enabled +0 +SET @start_global_value = @@global.rpl_semi_sync_master_enabled; +select @@global.rpl_semi_sync_master_enabled in (0,1); +@@global.rpl_semi_sync_master_enabled in (0,1) +1 +select @@session.rpl_semi_sync_master_enabled; +ERROR HY000: Variable 'rpl_semi_sync_master_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled OFF +show session variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled OFF +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED OFF +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED OFF +set global rpl_semi_sync_master_enabled=0; +set session rpl_semi_sync_master_enabled=0; +ERROR HY000: Variable 'rpl_semi_sync_master_enabled' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_enabled; +@@global.rpl_semi_sync_master_enabled +0 +select @@session.rpl_semi_sync_master_enabled; +ERROR HY000: Variable 'rpl_semi_sync_master_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled OFF +show session variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled OFF +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED OFF +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED OFF +set global rpl_semi_sync_master_enabled=1; +set session rpl_semi_sync_master_enabled=1; +ERROR HY000: Variable 'rpl_semi_sync_master_enabled' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_enabled; +@@global.rpl_semi_sync_master_enabled +-1 +select @@session.rpl_semi_sync_master_enabled; +ERROR HY000: Variable 'rpl_semi_sync_master_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled ON +show session variables like 'rpl_semi_sync_master_enabled'; +Variable_name Value +rpl_semi_sync_master_enabled ON +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED ON +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_ENABLED ON +set global rpl_semi_sync_master_enabled=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_enabled' +set global rpl_semi_sync_master_enabled=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_enabled' +set global rpl_semi_sync_master_enabled="some text"; +ERROR 42000: Variable 'rpl_semi_sync_master_enabled' can't be set to the value of 'some text' +SET @@global.rpl_semi_sync_master_enabled = @start_global_value; +select @@global.rpl_semi_sync_master_enabled; +@@global.rpl_semi_sync_master_enabled +0 +UNINSTALL PLUGIN rpl_semi_sync_master; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_timeout_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_timeout_basic.result new file mode 100644 index 00000000000..e77bcc1c12a --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_timeout_basic.result @@ -0,0 +1,54 @@ +INSTALL PLUGIN rpl_semi_sync_master SONAME 'semisync_master.so'; +select @@global.rpl_semi_sync_master_timeout; +@@global.rpl_semi_sync_master_timeout +10000 +SET @start_global_value = @@global.rpl_semi_sync_master_timeout; +Assuming value will not be more then 100 sec +select @@global.rpl_semi_sync_master_timeout between 1 and 100000; +@@global.rpl_semi_sync_master_timeout between 1 and 100000 +1 +select @@session.rpl_semi_sync_master_timeout; +ERROR HY000: Variable 'rpl_semi_sync_master_timeout' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_timeout'; +Variable_name Value +rpl_semi_sync_master_timeout 10000 +show session variables like 'rpl_semi_sync_master_timeout'; +Variable_name Value +rpl_semi_sync_master_timeout 10000 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_timeout'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TIMEOUT 10000 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_timeout'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TIMEOUT 10000 +set global rpl_semi_sync_master_timeout=42; +set session rpl_semi_sync_master_timeout=99; +ERROR HY000: Variable 'rpl_semi_sync_master_timeout' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_timeout; +@@global.rpl_semi_sync_master_timeout +42 +select @@session.rpl_semi_sync_master_timeout; +ERROR HY000: Variable 'rpl_semi_sync_master_timeout' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_timeout'; +Variable_name Value +rpl_semi_sync_master_timeout 42 +show session variables like 'rpl_semi_sync_master_timeout'; +Variable_name Value +rpl_semi_sync_master_timeout 42 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_timeout'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TIMEOUT 42 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_timeout'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TIMEOUT 42 +set global rpl_semi_sync_master_timeout=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_timeout' +set global rpl_semi_sync_master_timeout=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_timeout' +set global rpl_semi_sync_master_timeout="some text"; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_timeout' +SET @@global.rpl_semi_sync_master_timeout = @start_global_value; +select @@global.rpl_semi_sync_master_timeout; +@@global.rpl_semi_sync_master_timeout +10000 +UNINSTALL PLUGIN rpl_semi_sync_master; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_trace_level_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_trace_level_basic.result new file mode 100644 index 00000000000..55df5f57d9e --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_trace_level_basic.result @@ -0,0 +1,72 @@ +INSTALL PLUGIN rpl_semi_sync_master SONAME 'semisync_master.so'; +select @@global.rpl_semi_sync_master_trace_level; +@@global.rpl_semi_sync_master_trace_level +32 +SET @start_global_value = @@global.rpl_semi_sync_master_trace_level; +select @@global.rpl_semi_sync_master_trace_level in (1,16,32,64); +@@global.rpl_semi_sync_master_trace_level in (1,16,32,64) +1 +select @@session.rpl_semi_sync_master_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_master_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 32 +show session variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 32 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 32 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 32 +set global rpl_semi_sync_master_trace_level=16; +set session rpl_semi_sync_master_trace_level=99; +ERROR HY000: Variable 'rpl_semi_sync_master_trace_level' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_trace_level; +@@global.rpl_semi_sync_master_trace_level +16 +select @@session.rpl_semi_sync_master_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_master_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 16 +show session variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 16 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 16 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 16 +NOTE: Value can also be set to values that are combinations of values +set global rpl_semi_sync_master_trace_level=42; +select @@global.rpl_semi_sync_master_trace_level; +@@global.rpl_semi_sync_master_trace_level +42 +select @@session.rpl_semi_sync_master_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_master_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 42 +show session variables like 'rpl_semi_sync_master_trace_level'; +Variable_name Value +rpl_semi_sync_master_trace_level 42 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 42 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_TRACE_LEVEL 42 +set global rpl_semi_sync_master_trace_level=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_trace_level' +set global rpl_semi_sync_master_trace_level=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_trace_level' +set global rpl_semi_sync_master_trace_level="some text"; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_trace_level' +SET @@global.rpl_semi_sync_master_trace_level = @start_global_value; +select @@global.rpl_semi_sync_master_trace_level; +@@global.rpl_semi_sync_master_trace_level +32 +UNINSTALL PLUGIN rpl_semi_sync_master; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_wait_no_slave_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_wait_no_slave_basic.result new file mode 100644 index 00000000000..3d951b499ed --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_master_wait_no_slave_basic.result @@ -0,0 +1,73 @@ +INSTALL PLUGIN rpl_semi_sync_master SONAME 'semisync_master.so'; +select @@global.rpl_semi_sync_master_wait_no_slave; +@@global.rpl_semi_sync_master_wait_no_slave +1 +SET @start_global_value = @@global.rpl_semi_sync_master_wait_no_slave; +select @@global.rpl_semi_sync_master_wait_no_slave in (0,1); +@@global.rpl_semi_sync_master_wait_no_slave in (0,1) +1 +select @@session.rpl_semi_sync_master_wait_no_slave; +ERROR HY000: Variable 'rpl_semi_sync_master_wait_no_slave' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave ON +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave ON +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE ON +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE ON +set global rpl_semi_sync_master_wait_no_slave=0; +set session rpl_semi_sync_master_wait_no_slave=0; +ERROR HY000: Variable 'rpl_semi_sync_master_wait_no_slave' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_wait_no_slave; +@@global.rpl_semi_sync_master_wait_no_slave +0 +select @@session.rpl_semi_sync_master_wait_no_slave; +ERROR HY000: Variable 'rpl_semi_sync_master_wait_no_slave' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave OFF +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave OFF +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE OFF +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE OFF +set global rpl_semi_sync_master_wait_no_slave=1; +set session rpl_semi_sync_master_wait_no_slave=1; +ERROR HY000: Variable 'rpl_semi_sync_master_wait_no_slave' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_master_wait_no_slave; +@@global.rpl_semi_sync_master_wait_no_slave +1 +select @@session.rpl_semi_sync_master_wait_no_slave; +ERROR HY000: Variable 'rpl_semi_sync_master_wait_no_slave' is a GLOBAL variable +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave ON +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +Variable_name Value +rpl_semi_sync_master_wait_no_slave ON +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE ON +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_MASTER_WAIT_NO_SLAVE ON +set global rpl_semi_sync_master_wait_no_slave=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_wait_no_slave' +set global rpl_semi_sync_master_wait_no_slave=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_master_wait_no_slave' +set global rpl_semi_sync_master_wait_no_slave="some text"; +ERROR 42000: Variable 'rpl_semi_sync_master_wait_no_slave' can't be set to the value of 'some text' +SET @@global.rpl_semi_sync_master_wait_no_slave = @start_global_value; +select @@global.rpl_semi_sync_master_wait_no_slave; +@@global.rpl_semi_sync_master_wait_no_slave +1 +UNINSTALL PLUGIN rpl_semi_sync_master; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_enabled_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_enabled_basic.result new file mode 100644 index 00000000000..25688f55ecd --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_enabled_basic.result @@ -0,0 +1,73 @@ +INSTALL PLUGIN rpl_semi_sync_slave SONAME 'semisync_slave.so'; +select @@global.rpl_semi_sync_slave_enabled; +@@global.rpl_semi_sync_slave_enabled +0 +SET @start_global_value = @@global.rpl_semi_sync_slave_enabled; +select @@global.rpl_semi_sync_slave_enabled in (0,1); +@@global.rpl_semi_sync_slave_enabled in (0,1) +1 +select @@session.rpl_semi_sync_slave_enabled; +ERROR HY000: Variable 'rpl_semi_sync_slave_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled OFF +show session variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled OFF +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED OFF +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED OFF +set global rpl_semi_sync_slave_enabled=0; +set session rpl_semi_sync_slave_enabled=0; +ERROR HY000: Variable 'rpl_semi_sync_slave_enabled' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_slave_enabled; +@@global.rpl_semi_sync_slave_enabled +0 +select @@session.rpl_semi_sync_slave_enabled; +ERROR HY000: Variable 'rpl_semi_sync_slave_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled OFF +show session variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled OFF +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED OFF +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED OFF +set global rpl_semi_sync_slave_enabled=1; +set session rpl_semi_sync_slave_enabled=1; +ERROR HY000: Variable 'rpl_semi_sync_slave_enabled' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_slave_enabled; +@@global.rpl_semi_sync_slave_enabled +-1 +select @@session.rpl_semi_sync_slave_enabled; +ERROR HY000: Variable 'rpl_semi_sync_slave_enabled' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled ON +show session variables like 'rpl_semi_sync_slave_enabled'; +Variable_name Value +rpl_semi_sync_slave_enabled ON +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED ON +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_ENABLED ON +set global rpl_semi_sync_slave_enabled=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_slave_enabled' +set global rpl_semi_sync_slave_enabled=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_slave_enabled' +set global rpl_semi_sync_slave_enabled="some text"; +ERROR 42000: Variable 'rpl_semi_sync_slave_enabled' can't be set to the value of 'some text' +SET @@global.rpl_semi_sync_slave_enabled = @start_global_value; +select @@global.rpl_semi_sync_slave_enabled; +@@global.rpl_semi_sync_slave_enabled +0 +UNINSTALL PLUGIN rpl_semi_sync_slave; diff --git a/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_trace_level_basic.result b/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_trace_level_basic.result new file mode 100644 index 00000000000..f7796309aea --- /dev/null +++ b/mysql-test/suite/sys_vars/r/rpl_semi_sync_slave_trace_level_basic.result @@ -0,0 +1,72 @@ +INSTALL PLUGIN rpl_semi_sync_slave SONAME 'semisync_slave.so'; +select @@global.rpl_semi_sync_slave_trace_level; +@@global.rpl_semi_sync_slave_trace_level +32 +SET @start_global_value = @@global.rpl_semi_sync_slave_trace_level; +select @@global.rpl_semi_sync_slave_trace_level in (1,16,32,64); +@@global.rpl_semi_sync_slave_trace_level in (1,16,32,64) +1 +select @@session.rpl_semi_sync_slave_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_slave_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 32 +show session variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 32 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 32 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 32 +set global rpl_semi_sync_slave_trace_level=16; +set session rpl_semi_sync_slave_trace_level=99; +ERROR HY000: Variable 'rpl_semi_sync_slave_trace_level' is a GLOBAL variable and should be set with SET GLOBAL +select @@global.rpl_semi_sync_slave_trace_level; +@@global.rpl_semi_sync_slave_trace_level +16 +select @@session.rpl_semi_sync_slave_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_slave_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 16 +show session variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 16 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 16 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 16 +NOTE: Value can also be set to values that are combinations of values +set global rpl_semi_sync_slave_trace_level=42; +select @@global.rpl_semi_sync_slave_trace_level; +@@global.rpl_semi_sync_slave_trace_level +42 +select @@session.rpl_semi_sync_slave_trace_level; +ERROR HY000: Variable 'rpl_semi_sync_slave_trace_level' is a GLOBAL variable +show global variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 42 +show session variables like 'rpl_semi_sync_slave_trace_level'; +Variable_name Value +rpl_semi_sync_slave_trace_level 42 +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 42 +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; +VARIABLE_NAME VARIABLE_VALUE +RPL_SEMI_SYNC_SLAVE_TRACE_LEVEL 42 +set global rpl_semi_sync_slave_trace_level=1.1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_slave_trace_level' +set global rpl_semi_sync_slave_trace_level=1e1; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_slave_trace_level' +set global rpl_semi_sync_slave_trace_level="some text"; +ERROR 42000: Incorrect argument type to variable 'rpl_semi_sync_slave_trace_level' +SET @@global.rpl_semi_sync_slave_trace_level = @start_global_value; +select @@global.rpl_semi_sync_slave_trace_level; +@@global.rpl_semi_sync_slave_trace_level +32 +UNINSTALL PLUGIN rpl_semi_sync_slave; diff --git a/mysql-test/suite/sys_vars/r/sql_log_update_basic.result b/mysql-test/suite/sys_vars/r/sql_log_update_basic.result index f48cf6870da..11cd039da00 100644 --- a/mysql-test/suite/sys_vars/r/sql_log_update_basic.result +++ b/mysql-test/suite/sys_vars/r/sql_log_update_basic.result @@ -23,15 +23,51 @@ SQL_LOG_UPDATE ON set global sql_log_update=1; Warnings: Note 1315 The update log is deprecated and replaced by the binary log; SET SQL_LOG_UPDATE has been ignored -select @@global.sql_log_update; -@@global.sql_log_update -1 set session sql_log_update=ON; Warnings: Note 1315 The update log is deprecated and replaced by the binary log; SET SQL_LOG_UPDATE has been ignored +select @@global.sql_log_update; +@@global.sql_log_update +1 select @@session.sql_log_update; @@session.sql_log_update 1 +show global variables like 'sql_log_update'; +Variable_name Value +sql_log_update ON +show session variables like 'sql_log_update'; +Variable_name Value +sql_log_update ON +select * from information_schema.global_variables where variable_name='sql_log_update'; +VARIABLE_NAME VARIABLE_VALUE +SQL_LOG_UPDATE ON +select * from information_schema.session_variables where variable_name='sql_log_update'; +VARIABLE_NAME VARIABLE_VALUE +SQL_LOG_UPDATE ON +set global sql_log_update=0; +Warnings: +Note 1315 The update log is deprecated and replaced by the binary log; SET SQL_LOG_UPDATE has been ignored +set session sql_log_update=OFF; +Warnings: +Note 1315 The update log is deprecated and replaced by the binary log; SET SQL_LOG_UPDATE has been ignored +select @@global.sql_log_update; +@@global.sql_log_update +0 +select @@session.sql_log_update; +@@session.sql_log_update +0 +show global variables like 'sql_log_update'; +Variable_name Value +sql_log_update OFF +show session variables like 'sql_log_update'; +Variable_name Value +sql_log_update OFF +select * from information_schema.global_variables where variable_name='sql_log_update'; +VARIABLE_NAME VARIABLE_VALUE +SQL_LOG_UPDATE OFF +select * from information_schema.session_variables where variable_name='sql_log_update'; +VARIABLE_NAME VARIABLE_VALUE +SQL_LOG_UPDATE OFF set global sql_log_update=1.1; ERROR 42000: Incorrect argument type to variable 'sql_log_update' set global sql_log_update=1e1; diff --git a/mysql-test/suite/sys_vars/r/sql_max_join_size_basic.result b/mysql-test/suite/sys_vars/r/sql_max_join_size_basic.result index 8aaea049b94..8ec2a60887f 100644 --- a/mysql-test/suite/sys_vars/r/sql_max_join_size_basic.result +++ b/mysql-test/suite/sys_vars/r/sql_max_join_size_basic.result @@ -23,15 +23,27 @@ SQL_MAX_JOIN_SIZE 18446744073709551615 set global sql_max_join_size=10; Warnings: Warning 1287 The syntax '@@sql_max_join_size' is deprecated and will be removed in MySQL 7.0. -select @@global.sql_max_join_size; -@@global.sql_max_join_size -10 set session sql_max_join_size=20; Warnings: Warning 1287 The syntax '@@sql_max_join_size' is deprecated and will be removed in MySQL 7.0. +select @@global.sql_max_join_size; +@@global.sql_max_join_size +10 select @@session.sql_max_join_size; @@session.sql_max_join_size 20 +show global variables like 'sql_max_join_size'; +Variable_name Value +sql_max_join_size 10 +show session variables like 'sql_max_join_size'; +Variable_name Value +sql_max_join_size 20 +select * from information_schema.global_variables where variable_name='sql_max_join_size'; +VARIABLE_NAME VARIABLE_VALUE +SQL_MAX_JOIN_SIZE 10 +select * from information_schema.session_variables where variable_name='sql_max_join_size'; +VARIABLE_NAME VARIABLE_VALUE +SQL_MAX_JOIN_SIZE 20 set global sql_max_join_size=1.1; ERROR 42000: Incorrect argument type to variable 'sql_max_join_size' set global sql_max_join_size=1e1; diff --git a/mysql-test/suite/sys_vars/r/sql_select_limit_basic.result b/mysql-test/suite/sys_vars/r/sql_select_limit_basic.result index c601fa148ce..78119cd9dff 100644 --- a/mysql-test/suite/sys_vars/r/sql_select_limit_basic.result +++ b/mysql-test/suite/sys_vars/r/sql_select_limit_basic.result @@ -21,13 +21,25 @@ select * from information_schema.session_variables where variable_name='sql_sele VARIABLE_NAME VARIABLE_VALUE SQL_SELECT_LIMIT 18446744073709551615 set global sql_select_limit=10; +set session sql_select_limit=20; select @@global.sql_select_limit; @@global.sql_select_limit 10 -set session sql_select_limit=20; select @@session.sql_select_limit; @@session.sql_select_limit 20 +show global variables like 'sql_select_limit'; +Variable_name Value +sql_select_limit 10 +show session variables like 'sql_select_limit'; +Variable_name Value +sql_select_limit 20 +select * from information_schema.global_variables where variable_name='sql_select_limit'; +VARIABLE_NAME VARIABLE_VALUE +SQL_SELECT_LIMIT 10 +select * from information_schema.session_variables where variable_name='sql_select_limit'; +VARIABLE_NAME VARIABLE_VALUE +SQL_SELECT_LIMIT 20 set global sql_select_limit=1.1; ERROR 42000: Incorrect argument type to variable 'sql_select_limit' set global sql_select_limit=1e1; diff --git a/mysql-test/suite/sys_vars/r/thread_cache_size_basic.result b/mysql-test/suite/sys_vars/r/thread_cache_size_basic.result index 1c802f1afdd..83501ca929b 100644 --- a/mysql-test/suite/sys_vars/r/thread_cache_size_basic.result +++ b/mysql-test/suite/sys_vars/r/thread_cache_size_basic.result @@ -23,6 +23,12 @@ set global thread_cache_size=1; select @@global.thread_cache_size; @@global.thread_cache_size 1 +select * from information_schema.global_variables where variable_name='thread_cache_size'; +VARIABLE_NAME VARIABLE_VALUE +THREAD_CACHE_SIZE 1 +select * from information_schema.session_variables where variable_name='thread_cache_size'; +VARIABLE_NAME VARIABLE_VALUE +THREAD_CACHE_SIZE 1 set session thread_cache_size=1; ERROR HY000: Variable 'thread_cache_size' is a GLOBAL variable and should be set with SET GLOBAL set global thread_cache_size=1.1; diff --git a/mysql-test/suite/sys_vars/t/all_vars-master.opt b/mysql-test/suite/sys_vars/t/all_vars-master.opt new file mode 100644 index 00000000000..3eec696ce86 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/all_vars-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT --loose-innodb diff --git a/mysql-test/suite/sys_vars/t/all_vars.test b/mysql-test/suite/sys_vars/t/all_vars.test index 6a18b5e3d37..0e831319898 100644 --- a/mysql-test/suite/sys_vars/t/all_vars.test +++ b/mysql-test/suite/sys_vars/t/all_vars.test @@ -15,6 +15,22 @@ --source include/not_embedded.inc +# 2010-01-28 OBN Added support to load 'innodb' and 'semisync' if possible. +# As we need to have there variables loaded if the components exist but do +# not want the test skiped if they are not, we cannot use the 'have_xxx' mecanizm. +# Added an 'all_vars-master.opt' file that includes +# "$SEMISYNC_PLUGIN_OPT --loose-innodb" (see $SEMISYNC_PLUGIN_OPT setting in mysql-test-run.pl) +# and logic similar to 'include/have_semisync_plugin.inc' that will load semisync plugin +if (`SELECT @@have_dynamic_loading = 'YES' AND LENGTH('$SEMISYNC_MASTER_PLUGIN') > 0`) +{ + --disable_query_log + eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; + eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; + --enable_query_log +} + + + # # This test verifies that *all* system variables are tested # by the sys_vars suite. For every system variable @@ -58,3 +74,12 @@ select variable_name as `There should be *no* variables listed below:` from t2 drop table t1; drop table t2; + +# Unloading the semisync plugins in case they were loaded +if (`SELECT @@have_dynamic_loading = 'YES' AND LENGTH('$SEMISYNC_MASTER_PLUGIN') > 0`) +{ + --disable_query_log + UNINSTALL PLUGIN rpl_semi_sync_master; + UNINSTALL PLUGIN rpl_semi_sync_slave; + --enable_query_log +} diff --git a/mysql-test/suite/sys_vars/t/innodb_adaptive_flushing_basic.test b/mysql-test/suite/sys_vars/t/innodb_adaptive_flushing_basic.test new file mode 100644 index 00000000000..236b652f9c6 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_adaptive_flushing_basic.test @@ -0,0 +1,70 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_adaptive_flushing; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_flushing in (0, 1); +select @@global.innodb_adaptive_flushing; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_adaptive_flushing; +show global variables like 'innodb_adaptive_flushing'; +show session variables like 'innodb_adaptive_flushing'; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; + +# +# show that it's writable +# +set global innodb_adaptive_flushing='OFF'; +select @@global.innodb_adaptive_flushing; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +set @@global.innodb_adaptive_flushing=1; +select @@global.innodb_adaptive_flushing; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +set global innodb_adaptive_flushing=0; +select @@global.innodb_adaptive_flushing; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +set @@global.innodb_adaptive_flushing='ON'; +select @@global.innodb_adaptive_flushing; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +--error ER_GLOBAL_VARIABLE +set session innodb_adaptive_flushing='OFF'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_adaptive_flushing='ON'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_adaptive_flushing=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_adaptive_flushing=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_adaptive_flushing=2; +--echo NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_adaptive_flushing=-3; +select @@global.innodb_adaptive_flushing; +select * from information_schema.global_variables where variable_name='innodb_adaptive_flushing'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_flushing'; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_adaptive_flushing='AUTO'; + +# +# Cleanup +# + +SET @@global.innodb_adaptive_flushing = @start_global_value; +SELECT @@global.innodb_adaptive_flushing; diff --git a/mysql-test/suite/sys_vars/t/innodb_adaptive_hash_index_basic.test b/mysql-test/suite/sys_vars/t/innodb_adaptive_hash_index_basic.test new file mode 100644 index 00000000000..d6d48ab460c --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_adaptive_hash_index_basic.test @@ -0,0 +1,70 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_adaptive_hash_index; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_hash_index in (0, 1); +select @@global.innodb_adaptive_hash_index; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_adaptive_hash_index; +show global variables like 'innodb_adaptive_hash_index'; +show session variables like 'innodb_adaptive_hash_index'; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; + +# +# show that it's writable +# +set global innodb_adaptive_hash_index='OFF'; +select @@global.innodb_adaptive_hash_index; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +set @@global.innodb_adaptive_hash_index=1; +select @@global.innodb_adaptive_hash_index; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +set global innodb_adaptive_hash_index=0; +select @@global.innodb_adaptive_hash_index; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +set @@global.innodb_adaptive_hash_index='ON'; +select @@global.innodb_adaptive_hash_index; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +--error ER_GLOBAL_VARIABLE +set session innodb_adaptive_hash_index='OFF'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_adaptive_hash_index='ON'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_adaptive_hash_index=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_adaptive_hash_index=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_adaptive_hash_index=2; +--echo NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_adaptive_hash_index=-3; +select @@global.innodb_adaptive_hash_index; +select * from information_schema.global_variables where variable_name='innodb_adaptive_hash_index'; +select * from information_schema.session_variables where variable_name='innodb_adaptive_hash_index'; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_adaptive_hash_index='AUTO'; + +# +# Cleanup +# + +SET @@global.innodb_adaptive_hash_index = @start_global_value; +SELECT @@global.innodb_adaptive_hash_index; diff --git a/mysql-test/suite/sys_vars/t/innodb_change_buffering_basic.test b/mysql-test/suite/sys_vars/t/innodb_change_buffering_basic.test new file mode 100644 index 00000000000..65e36aa9cb3 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_change_buffering_basic.test @@ -0,0 +1,59 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_change_buffering; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'inserts' and 'none' +select @@global.innodb_change_buffering in ('inserts', 'none'); +select @@global.innodb_change_buffering; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_change_buffering; +show global variables like 'innodb_change_buffering'; +show session variables like 'innodb_change_buffering'; +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; + +# +# show that it's writable +# +set global innodb_change_buffering='none'; +select @@global.innodb_change_buffering; +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; +set @@global.innodb_change_buffering='inserts'; +select @@global.innodb_change_buffering; +select * from information_schema.global_variables where variable_name='innodb_change_buffering'; +select * from information_schema.session_variables where variable_name='innodb_change_buffering'; +--error ER_GLOBAL_VARIABLE +set session innodb_change_buffering='some'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_change_buffering='some'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_change_buffering=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_change_buffering=1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_change_buffering=-2; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_change_buffering=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_change_buffering='some'; + +# +# Cleanup +# + +SET @@global.innodb_change_buffering = @start_global_value; +SELECT @@global.innodb_change_buffering; diff --git a/mysql-test/suite/sys_vars/t/innodb_file_format_basic.test b/mysql-test/suite/sys_vars/t/innodb_file_format_basic.test new file mode 100644 index 00000000000..bfc092f2f05 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_file_format_basic.test @@ -0,0 +1,55 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_file_format; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'Antelope' and 'Barracuda' +select @@global.innodb_file_format in ('Antelope', 'Barracuda'); +select @@global.innodb_file_format; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_file_format; +show global variables like 'innodb_file_format'; +show session variables like 'innodb_file_format'; +select * from information_schema.global_variables where variable_name='innodb_file_format'; +select * from information_schema.session_variables where variable_name='innodb_file_format'; + +# +# show that it's writable +# +set global innodb_file_format='Antelope'; +select @@global.innodb_file_format; +select * from information_schema.global_variables where variable_name='innodb_file_format'; +select * from information_schema.session_variables where variable_name='innodb_file_format'; +set @@global.innodb_file_format='Barracuda'; +select @@global.innodb_file_format; +select * from information_schema.global_variables where variable_name='innodb_file_format'; +select * from information_schema.session_variables where variable_name='innodb_file_format'; +--error ER_GLOBAL_VARIABLE +set session innodb_file_format='Salmon'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_file_format='Salmon'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_file_format=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_file_format=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_file_format='Salmon'; + +# +# Cleanup +# + +SET @@global.innodb_file_format = @start_global_value; +SELECT @@global.innodb_file_format; diff --git a/mysql-test/suite/sys_vars/t/innodb_file_format_check_basic.test b/mysql-test/suite/sys_vars/t/innodb_file_format_check_basic.test new file mode 100644 index 00000000000..4c60957561c --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_file_format_check_basic.test @@ -0,0 +1,55 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_file_format_check; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'Antelope' and 'Barracuda' +select @@global.innodb_file_format_check in ('Antelope', 'Barracuda'); +select @@global.innodb_file_format_check; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_file_format_check; +show global variables like 'innodb_file_format_check'; +show session variables like 'innodb_file_format_check'; +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; + +# +# show that it's writable +# +set global innodb_file_format_check='Antelope'; +select @@global.innodb_file_format_check; +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; +set @@global.innodb_file_format_check='Barracuda'; +select @@global.innodb_file_format_check; +select * from information_schema.global_variables where variable_name='innodb_file_format_check'; +select * from information_schema.session_variables where variable_name='innodb_file_format_check'; +--error ER_GLOBAL_VARIABLE +set session innodb_file_format_check='Salmon'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_file_format_check='Salmon'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_file_format_check=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_file_format_check=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_file_format_check='Salmon'; + +# +# Cleanup +# + +SET @@global.innodb_file_format_check = @start_global_value; +SELECT @@global.innodb_file_format_check; diff --git a/mysql-test/suite/sys_vars/t/innodb_io_capacity_basic.test b/mysql-test/suite/sys_vars/t/innodb_io_capacity_basic.test new file mode 100644 index 00000000000..3f00b50cf08 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_io_capacity_basic.test @@ -0,0 +1,58 @@ + + +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_io_capacity; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid value 100 or more +select @@global.innodb_io_capacity > 99; +select @@global.innodb_io_capacity; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_io_capacity; +show global variables like 'innodb_io_capacity'; +show session variables like 'innodb_io_capacity'; +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +select * from information_schema.session_variables where variable_name='innodb_io_capacity'; + +# +# show that it's writable +# +set global innodb_io_capacity=123; +select @@global.innodb_io_capacity; +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +select * from information_schema.session_variables where variable_name='innodb_io_capacity'; +--error ER_GLOBAL_VARIABLE +set session innodb_io_capacity=444; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_io_capacity=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_io_capacity=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_io_capacity="foo"; + +set global innodb_io_capacity=7; +select @@global.innodb_io_capacity; +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; +set global innodb_io_capacity=-7; +select @@global.innodb_io_capacity; +select * from information_schema.global_variables where variable_name='innodb_io_capacity'; + +# +# min/max values +# +set global innodb_io_capacity=100; +select @@global.innodb_io_capacity; + +SET @@global.innodb_io_capacity = @start_global_value; +SELECT @@global.innodb_io_capacity; diff --git a/mysql-test/suite/sys_vars/t/innodb_old_blocks_pct_basic.test b/mysql-test/suite/sys_vars/t/innodb_old_blocks_pct_basic.test new file mode 100644 index 00000000000..0dcef3bb09f --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_old_blocks_pct_basic.test @@ -0,0 +1,63 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_old_blocks_pct; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are between 5 and 95 +select @@global.innodb_old_blocks_pct between 5 and 95; +select @@global.innodb_old_blocks_pct; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_old_blocks_pct; +show global variables like 'innodb_old_blocks_pct'; +show session variables like 'innodb_old_blocks_pct'; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +select * from information_schema.session_variables where variable_name='innodb_old_blocks_pct'; + +# +# show that it's writable +# +set global innodb_old_blocks_pct=10; +select @@global.innodb_old_blocks_pct; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +select * from information_schema.session_variables where variable_name='innodb_old_blocks_pct'; +--error ER_GLOBAL_VARIABLE +set session innodb_old_blocks_pct=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_pct=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_pct=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_pct="foo"; + +set global innodb_old_blocks_pct=4; +select @@global.innodb_old_blocks_pct; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +set global innodb_old_blocks_pct=-7; +select @@global.innodb_old_blocks_pct; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; +set global innodb_old_blocks_pct=96; +select @@global.innodb_old_blocks_pct; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_pct'; + +# +# min/max values +# +set global innodb_old_blocks_pct=5; +select @@global.innodb_old_blocks_pct; +set global innodb_old_blocks_pct=95; +select @@global.innodb_old_blocks_pct; + +SET @@global.innodb_old_blocks_pct = @start_global_value; +SELECT @@global.innodb_old_blocks_pct; diff --git a/mysql-test/suite/sys_vars/t/innodb_old_blocks_time_basic.test b/mysql-test/suite/sys_vars/t/innodb_old_blocks_time_basic.test new file mode 100644 index 00000000000..3efec2bbf15 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_old_blocks_time_basic.test @@ -0,0 +1,52 @@ + +# +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_old_blocks_time; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are zero or above +select @@global.innodb_old_blocks_time >=0; +select @@global.innodb_old_blocks_time; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_old_blocks_time; +show global variables like 'innodb_old_blocks_time'; +show session variables like 'innodb_old_blocks_time'; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; +select * from information_schema.session_variables where variable_name='innodb_old_blocks_time'; + +# +# show that it's writable +# +set global innodb_old_blocks_time=10; +select @@global.innodb_old_blocks_time; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; +select * from information_schema.session_variables where variable_name='innodb_old_blocks_time'; +--error ER_GLOBAL_VARIABLE +set session innodb_old_blocks_time=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_time=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_time=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_old_blocks_time="foo"; + +set global innodb_old_blocks_time=-7; +select @@global.innodb_old_blocks_time; +select * from information_schema.global_variables where variable_name='innodb_old_blocks_time'; + +# +# cleanup +# +SET @@global.innodb_old_blocks_time = @start_global_value; +SELECT @@global.innodb_old_blocks_time; diff --git a/mysql-test/suite/sys_vars/t/innodb_read_ahead_threshold_basic.test b/mysql-test/suite/sys_vars/t/innodb_read_ahead_threshold_basic.test new file mode 100644 index 00000000000..1298a28b3d3 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_read_ahead_threshold_basic.test @@ -0,0 +1,60 @@ + + +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_read_ahead_threshold; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are between 0 and 64 +select @@global.innodb_read_ahead_threshold between 0 and 64; +select @@global.innodb_read_ahead_threshold; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_read_ahead_threshold; +show global variables like 'innodb_read_ahead_threshold'; +show session variables like 'innodb_read_ahead_threshold'; +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +select * from information_schema.session_variables where variable_name='innodb_read_ahead_threshold'; + +# +# show that it's writable +# +set global innodb_read_ahead_threshold=10; +select @@global.innodb_read_ahead_threshold; +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +select * from information_schema.session_variables where variable_name='innodb_read_ahead_threshold'; +--error ER_GLOBAL_VARIABLE +set session innodb_read_ahead_threshold=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_read_ahead_threshold=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_read_ahead_threshold=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_read_ahead_threshold="foo"; + +set global innodb_read_ahead_threshold=-7; +select @@global.innodb_read_ahead_threshold; +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; +set global innodb_read_ahead_threshold=96; +select @@global.innodb_read_ahead_threshold; +select * from information_schema.global_variables where variable_name='innodb_read_ahead_threshold'; + +# +# min/max values +# +set global innodb_read_ahead_threshold=0; +select @@global.innodb_read_ahead_threshold; +set global innodb_read_ahead_threshold=64; +select @@global.innodb_read_ahead_threshold; + +SET @@global.innodb_read_ahead_threshold = @start_global_value; +SELECT @@global.innodb_read_ahead_threshold; diff --git a/mysql-test/suite/sys_vars/t/innodb_read_io_threads_basic.test b/mysql-test/suite/sys_vars/t/innodb_read_io_threads_basic.test new file mode 100644 index 00000000000..14426395d6c --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_read_io_threads_basic.test @@ -0,0 +1,26 @@ + +# +# 2010-01-27 OBN - Added (this variable is also covered in innodb_file_io_threads_basic.test) +# + +--source include/have_innodb.inc + +# +# show the global and session values; +# +select @@global.innodb_read_io_threads; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_read_io_threads; +show global variables like 'innodb_read_io_threads'; +show session variables like 'innodb_read_io_threads'; +select * from information_schema.global_variables where variable_name='innodb_read_io_threads'; +select * from information_schema.session_variables where variable_name='innodb_read_io_threads'; + +# +# show that it's read-only +# +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set global innodb_read_io_threads=1; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set session innodb_read_io_threads=1; + diff --git a/mysql-test/suite/sys_vars/t/innodb_replication_delay_basic.test b/mysql-test/suite/sys_vars/t/innodb_replication_delay_basic.test new file mode 100644 index 00000000000..e495de46611 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_replication_delay_basic.test @@ -0,0 +1,52 @@ + +# +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_replication_delay; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are zero or above +select @@global.innodb_replication_delay >=0; +select @@global.innodb_replication_delay; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_replication_delay; +show global variables like 'innodb_replication_delay'; +show session variables like 'innodb_replication_delay'; +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; +select * from information_schema.session_variables where variable_name='innodb_replication_delay'; + +# +# show that it's writable +# +set global innodb_replication_delay=10; +select @@global.innodb_replication_delay; +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; +select * from information_schema.session_variables where variable_name='innodb_replication_delay'; +--error ER_GLOBAL_VARIABLE +set session innodb_replication_delay=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_replication_delay=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_replication_delay=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_replication_delay="foo"; + +set global innodb_replication_delay=-7; +select @@global.innodb_replication_delay; +select * from information_schema.global_variables where variable_name='innodb_replication_delay'; + +# +# cleanup +# +SET @@global.innodb_replication_delay = @start_global_value; +SELECT @@global.innodb_replication_delay; diff --git a/mysql-test/suite/sys_vars/t/innodb_spin_wait_delay_basic.test b/mysql-test/suite/sys_vars/t/innodb_spin_wait_delay_basic.test new file mode 100644 index 00000000000..8f2eee08b6a --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_spin_wait_delay_basic.test @@ -0,0 +1,52 @@ + +# +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_spin_wait_delay; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are zero or above +select @@global.innodb_spin_wait_delay >=0; +select @@global.innodb_spin_wait_delay; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_spin_wait_delay; +show global variables like 'innodb_spin_wait_delay'; +show session variables like 'innodb_spin_wait_delay'; +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; +select * from information_schema.session_variables where variable_name='innodb_spin_wait_delay'; + +# +# show that it's writable +# +set global innodb_spin_wait_delay=10; +select @@global.innodb_spin_wait_delay; +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; +select * from information_schema.session_variables where variable_name='innodb_spin_wait_delay'; +--error ER_GLOBAL_VARIABLE +set session innodb_spin_wait_delay=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_spin_wait_delay=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_spin_wait_delay=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_spin_wait_delay="foo"; + +set global innodb_spin_wait_delay=-7; +select @@global.innodb_spin_wait_delay; +select * from information_schema.global_variables where variable_name='innodb_spin_wait_delay'; + +# +# cleanup +# +SET @@global.innodb_spin_wait_delay = @start_global_value; +SELECT @@global.innodb_spin_wait_delay; diff --git a/mysql-test/suite/sys_vars/t/innodb_stats_on_metadata_basic.test b/mysql-test/suite/sys_vars/t/innodb_stats_on_metadata_basic.test new file mode 100644 index 00000000000..e6d59997ac6 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_stats_on_metadata_basic.test @@ -0,0 +1,70 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_stats_on_metadata; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are 'ON' and 'OFF' +select @@global.innodb_stats_on_metadata in (0, 1); +select @@global.innodb_stats_on_metadata; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_stats_on_metadata; +show global variables like 'innodb_stats_on_metadata'; +show session variables like 'innodb_stats_on_metadata'; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; + +# +# show that it's writable +# +set global innodb_stats_on_metadata='OFF'; +select @@global.innodb_stats_on_metadata; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +set @@global.innodb_stats_on_metadata=1; +select @@global.innodb_stats_on_metadata; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +set global innodb_stats_on_metadata=0; +select @@global.innodb_stats_on_metadata; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +set @@global.innodb_stats_on_metadata='ON'; +select @@global.innodb_stats_on_metadata; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +--error ER_GLOBAL_VARIABLE +set session innodb_stats_on_metadata='OFF'; +--error ER_GLOBAL_VARIABLE +set @@session.innodb_stats_on_metadata='ON'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_stats_on_metadata=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_stats_on_metadata=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_stats_on_metadata=2; +--echo NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_stats_on_metadata=-3; +select @@global.innodb_stats_on_metadata; +select * from information_schema.global_variables where variable_name='innodb_stats_on_metadata'; +select * from information_schema.session_variables where variable_name='innodb_stats_on_metadata'; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_stats_on_metadata='AUTO'; + +# +# Cleanup +# + +SET @@global.innodb_stats_on_metadata = @start_global_value; +SELECT @@global.innodb_stats_on_metadata; diff --git a/mysql-test/suite/sys_vars/t/innodb_stats_sample_pages_basic.test b/mysql-test/suite/sys_vars/t/innodb_stats_sample_pages_basic.test new file mode 100644 index 00000000000..2c91f11405d --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_stats_sample_pages_basic.test @@ -0,0 +1,52 @@ + +# +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_stats_sample_pages; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are one or above +select @@global.innodb_stats_sample_pages >=1; +select @@global.innodb_stats_sample_pages; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_stats_sample_pages; +show global variables like 'innodb_stats_sample_pages'; +show session variables like 'innodb_stats_sample_pages'; +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; +select * from information_schema.session_variables where variable_name='innodb_stats_sample_pages'; + +# +# show that it's writable +# +set global innodb_stats_sample_pages=10; +select @@global.innodb_stats_sample_pages; +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; +select * from information_schema.session_variables where variable_name='innodb_stats_sample_pages'; +--error ER_GLOBAL_VARIABLE +set session innodb_stats_sample_pages=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_stats_sample_pages=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_stats_sample_pages=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_stats_sample_pages="foo"; + +set global innodb_stats_sample_pages=-7; +select @@global.innodb_stats_sample_pages; +select * from information_schema.global_variables where variable_name='innodb_stats_sample_pages'; + +# +# cleanup +# +SET @@global.innodb_stats_sample_pages = @start_global_value; +SELECT @@global.innodb_stats_sample_pages; diff --git a/mysql-test/suite/sys_vars/t/innodb_strict_mode_basic.test b/mysql-test/suite/sys_vars/t/innodb_strict_mode_basic.test new file mode 100644 index 00000000000..53fbdca2d32 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_strict_mode_basic.test @@ -0,0 +1,84 @@ + + +# 2010-01-25 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_strict_mode; +SELECT @start_global_value; + +# +# exists as global and session +# +--echo Valid values are 'ON' and 'OFF' +select @@global.innodb_strict_mode in (0, 1); +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode in (0, 1); +select @@session.innodb_strict_mode; +show global variables like 'innodb_strict_mode'; +show session variables like 'innodb_strict_mode'; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; + +# +# show that it's writable +# +set global innodb_strict_mode='OFF'; +set session innodb_strict_mode='OFF'; +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +set @@global.innodb_strict_mode=1; +set @@session.innodb_strict_mode=1; +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +set global innodb_strict_mode=0; +set session innodb_strict_mode=0; +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; +set @@global.innodb_strict_mode='ON'; +set @@session.innodb_strict_mode='ON'; +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_strict_mode=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set session innodb_strict_mode=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_strict_mode=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set session innodb_strict_mode=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_strict_mode=2; +--error ER_WRONG_VALUE_FOR_VAR +set session innodb_strict_mode=2; +--error ER_WRONG_VALUE_FOR_VAR +set global innodb_strict_mode='AUTO'; +--error ER_WRONG_VALUE_FOR_VAR +set session innodb_strict_mode='AUTO'; +--echo NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643) +set global innodb_strict_mode=-3; +set session innodb_strict_mode=-7; +select @@global.innodb_strict_mode; +select @@session.innodb_strict_mode; +select * from information_schema.global_variables where variable_name='innodb_strict_mode'; +select * from information_schema.session_variables where variable_name='innodb_strict_mode'; + +# +# Cleanup +# + +SET @@global.innodb_strict_mode = @start_global_value; +SELECT @@global.innodb_strict_mode; diff --git a/mysql-test/suite/sys_vars/t/innodb_thread_sleep_delay_basic.test b/mysql-test/suite/sys_vars/t/innodb_thread_sleep_delay_basic.test new file mode 100644 index 00000000000..7156f309a64 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_thread_sleep_delay_basic.test @@ -0,0 +1,52 @@ + +# +# 2010-01-27 - Added +# + +--source include/have_innodb.inc + +SET @start_global_value = @@global.innodb_thread_sleep_delay; +SELECT @start_global_value; + +# +# exists as global only +# +--echo Valid values are zero or above +select @@global.innodb_thread_sleep_delay >=0; +select @@global.innodb_thread_sleep_delay; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_thread_sleep_delay; +show global variables like 'innodb_thread_sleep_delay'; +show session variables like 'innodb_thread_sleep_delay'; +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; +select * from information_schema.session_variables where variable_name='innodb_thread_sleep_delay'; + +# +# show that it's writable +# +set global innodb_thread_sleep_delay=10; +select @@global.innodb_thread_sleep_delay; +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; +select * from information_schema.session_variables where variable_name='innodb_thread_sleep_delay'; +--error ER_GLOBAL_VARIABLE +set session innodb_thread_sleep_delay=1; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_thread_sleep_delay=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_thread_sleep_delay=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global innodb_thread_sleep_delay="foo"; + +set global innodb_thread_sleep_delay=-7; +select @@global.innodb_thread_sleep_delay; +select * from information_schema.global_variables where variable_name='innodb_thread_sleep_delay'; + +# +# cleanup +# +SET @@global.innodb_thread_sleep_delay = @start_global_value; +SELECT @@global.innodb_thread_sleep_delay; diff --git a/mysql-test/suite/sys_vars/t/innodb_use_sys_malloc_basic.test b/mysql-test/suite/sys_vars/t/innodb_use_sys_malloc_basic.test new file mode 100644 index 00000000000..21f3e904547 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_use_sys_malloc_basic.test @@ -0,0 +1,28 @@ + +# +# 2010-01-27 OBN - Added +# + +--source include/have_innodb.inc + +# +# show the global and session values; +# +--echo Valid values are 'ON' and 'OFF' +select @@global.innodb_adaptive_flushing in (0, 1); +select @@global.innodb_use_sys_malloc; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_use_sys_malloc; +show global variables like 'innodb_use_sys_malloc'; +show session variables like 'innodb_use_sys_malloc'; +select * from information_schema.global_variables where variable_name='innodb_use_sys_malloc'; +select * from information_schema.session_variables where variable_name='innodb_use_sys_malloc'; + +# +# show that it's read-only +# +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set global innodb_use_sys_malloc=1; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set session innodb_use_sys_malloc=1; + diff --git a/mysql-test/suite/sys_vars/t/innodb_version_basic.test b/mysql-test/suite/sys_vars/t/innodb_version_basic.test new file mode 100644 index 00000000000..6ee2adf6cf9 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_version_basic.test @@ -0,0 +1,28 @@ + +# +# 2010-01-27 OBN - Added +# + +--source include/have_innodb.inc + +# +# show the global and session values; +# +--let $inno_ver= `select @@global.innodb_version` +--replace_result $inno_ver x.y.z +select @@global.innodb_version; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_version; +--echo show global variables like 'innodb_version' disabled so to not change with every version; +--echo show session variables like 'innodb_version' disabled so to not change with every version; +select VARIABLE_VALUE=@@global.innodb_version from information_schema.global_variables where variable_name='innodb_version'; +select VARIABLE_VALUE=@@global.innodb_version from information_schema.session_variables where variable_name='innodb_version'; + +# +# show that it's read-only +# +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set global innodb_version=1; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set session innodb_version=1; + diff --git a/mysql-test/suite/sys_vars/t/innodb_write_io_threads_basic.test b/mysql-test/suite/sys_vars/t/innodb_write_io_threads_basic.test new file mode 100644 index 00000000000..8efa6576a66 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/innodb_write_io_threads_basic.test @@ -0,0 +1,26 @@ + +# +# 2010-01-27 OBN - Added (this variable is also covered in innodb_file_io_threads_basic.test) +# + +--source include/have_innodb.inc + +# +# show the global and session values; +# +select @@global.innodb_write_io_threads; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.innodb_write_io_threads; +show global variables like 'innodb_write_io_threads'; +show session variables like 'innodb_write_io_threads'; +select * from information_schema.global_variables where variable_name='innodb_write_io_threads'; +select * from information_schema.session_variables where variable_name='innodb_write_io_threads'; + +# +# show that it's read-only +# +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set global innodb_write_io_threads=1; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +set session innodb_write_io_threads=1; + diff --git a/mysql-test/suite/sys_vars/t/last_insert_id_basic.test b/mysql-test/suite/sys_vars/t/last_insert_id_basic.test index a2e0116f11d..ca971c660ca 100644 --- a/mysql-test/suite/sys_vars/t/last_insert_id_basic.test +++ b/mysql-test/suite/sys_vars/t/last_insert_id_basic.test @@ -2,6 +2,8 @@ # # exists as a session only # +# 2010-01-20 OBN - Added check for variable value matching I_S tables +# --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@global.last_insert_id; select @@session.last_insert_id; @@ -13,10 +15,16 @@ select * from information_schema.session_variables where variable_name='last_ins # # show that it's writable # -set session last_insert_id=1; -select @@session.last_insert_id; --error ER_LOCAL_VARIABLE -set global last_insert_id=1; +set global last_insert_id=99; +set session last_insert_id=42; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@global.last_insert_id; +select @@session.last_insert_id; +show global variables like 'last_insert_id'; +show session variables like 'last_insert_id'; +select * from information_schema.global_variables where variable_name='last_insert_id'; +select * from information_schema.session_variables where variable_name='last_insert_id'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/lc_messages_basic.test b/mysql-test/suite/sys_vars/t/lc_messages_basic.test index f8a25738285..a76381e8cb4 100644 --- a/mysql-test/suite/sys_vars/t/lc_messages_basic.test +++ b/mysql-test/suite/sys_vars/t/lc_messages_basic.test @@ -1,3 +1,8 @@ +# +# 2010-01-20 OBN - Added check for variable value matching I_S tables +# + + SET @start_global_value = @@global.lc_messages; SELECT @start_global_value; @@ -19,9 +24,11 @@ select @@global.lc_messages; set session lc_messages=2; select @@session.lc_messages; set global lc_messages="en_US"; -select @@global.lc_messages; set session lc_messages="en_GB"; +select @@global.lc_messages; select @@session.lc_messages; +select * from information_schema.global_variables where variable_name='lc_messages'; +select * from information_schema.session_variables where variable_name='lc_messages'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/log_slow_queries_basic.test b/mysql-test/suite/sys_vars/t/log_slow_queries_basic.test index 95dda5b73c9..22fe4dfaa6e 100644 --- a/mysql-test/suite/sys_vars/t/log_slow_queries_basic.test +++ b/mysql-test/suite/sys_vars/t/log_slow_queries_basic.test @@ -11,7 +11,7 @@ # Creation Date: 2008-03-16 # # Author: Salman Rawala # # # -# Description: Test Cases of Dynamic System Variable "log_slow_queries" # +# Description: Test Cases of Dynamic System Variable "log_slow_queries" # # that checks behavior of this variable in the following ways # # * Default Value # # * Valid & Invalid values # @@ -21,6 +21,10 @@ # Reference: http://dev.mysql.com/doc/refman/5.1/en/ # # server-options.html#option_mysqld_event-scheduler # # # +# # +# 2010-01-20 OBN - Added check for variable value matching I_S tables after # +# variable value change # +# # ################################################################################ --source include/load_sysvars.inc @@ -116,8 +120,14 @@ WHERE VARIABLE_NAME='log_slow_queries'; SET @@global.log_slow_queries = 0; SELECT @@global.log_slow_queries; +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; SET @@global.log_slow_queries = 1; SELECT @@global.log_slow_queries; +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; --echo '#---------------------FN_DYNVARS_004_07----------------------#' ################################################################### @@ -126,8 +136,14 @@ SELECT @@global.log_slow_queries; SET @@global.log_slow_queries = TRUE; SELECT @@global.log_slow_queries; +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; SET @@global.log_slow_queries = FALSE; SELECT @@global.log_slow_queries; +SELECT IF(@@global.log_slow_queries, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_slow_queries'; --echo '#---------------------FN_DYNVARS_004_08----------------------#' ############################################################################## diff --git a/mysql-test/suite/sys_vars/t/lower_case_file_system_basic.test b/mysql-test/suite/sys_vars/t/lower_case_file_system_basic.test index 6c15f188880..6c2af693128 100644 --- a/mysql-test/suite/sys_vars/t/lower_case_file_system_basic.test +++ b/mysql-test/suite/sys_vars/t/lower_case_file_system_basic.test @@ -1,17 +1,25 @@ # # only global # +# 2010-01-20 OBN - Modified to include check for valid values +# - Added check for variable value matching I_S tables +# select @@global.lower_case_file_system=2; --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@session.lower_case_file_system; ---replace_column 2 # -show global variables like 'lower_case_file_system'; ---replace_column 2 # -show session variables like 'lower_case_file_system'; ---replace_column 2 # -select * from information_schema.global_variables where variable_name='lower_case_file_system'; ---replace_column 2 # -select * from information_schema.session_variables where variable_name='lower_case_file_system'; + +# Show variable has a valid value +SELECT @@global.lower_case_file_system in (0,1); + +# Show that value of the variable matches the value in the GLOBAL I_S table +SELECT IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_file_system'; + +# Show that value of the variable matches the value in the SESSION I_S table +SELECT IF(@@global.lower_case_file_system, "ON", "OFF") = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='lower_case_file_system'; # # show that it's read-only diff --git a/mysql-test/suite/sys_vars/t/lower_case_table_names_basic.test b/mysql-test/suite/sys_vars/t/lower_case_table_names_basic.test index 8d6a3bb5ca6..eaa6c95974e 100644 --- a/mysql-test/suite/sys_vars/t/lower_case_table_names_basic.test +++ b/mysql-test/suite/sys_vars/t/lower_case_table_names_basic.test @@ -1,17 +1,26 @@ # # only global # +# 2010-01-20 OBN - Modified to include check for valid values +# - Added check for variable value matching I_S tables +# + select @@global.lower_case_table_names=20; --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@session.lower_case_table_names; ---replace_column 2 # -show global variables like 'lower_case_table_names'; ---replace_column 2 # -show session variables like 'lower_case_table_names'; ---replace_column 2 # -select * from information_schema.global_variables where variable_name='lower_case_table_names'; ---replace_column 2 # -select * from information_schema.session_variables where variable_name='lower_case_table_names'; + +# Show variable has a valid value +SELECT @@global.lower_case_table_names in (0,1,2); + +# Show that value of the variable matches the value in the GLOBAL I_S table +SELECT @@global.lower_case_table_names = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_table_names'; + +# Show that value of the variable matches the value in the SESSION I_S table +SELECT @@global.lower_case_table_names = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='lower_case_table_names'; # # show that it's read-only diff --git a/mysql-test/suite/sys_vars/t/max_join_size_basic.test b/mysql-test/suite/sys_vars/t/max_join_size_basic.test index 7566ab11520..bbe13457ee7 100644 --- a/mysql-test/suite/sys_vars/t/max_join_size_basic.test +++ b/mysql-test/suite/sys_vars/t/max_join_size_basic.test @@ -1,3 +1,11 @@ + + +# +# 2010-01-20 - OBN - Added check for variable value sameas I_S table +# after variable value change +# + + SET @start_global_value = @@global.max_join_size; SELECT @start_global_value; @@ -15,9 +23,13 @@ select * from information_schema.session_variables where variable_name='max_join # show that it's writable # set global max_join_size=10; -select @@global.max_join_size; set session max_join_size=20; +select @@global.max_join_size; select @@session.max_join_size; +show global variables like 'max_join_size'; +show session variables like 'max_join_size'; +select * from information_schema.global_variables where variable_name='max_join_size'; +select * from information_schema.session_variables where variable_name='max_join_size'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/old_alter_table_basic.test b/mysql-test/suite/sys_vars/t/old_alter_table_basic.test index 32d0f45ad25..cce180fea67 100644 --- a/mysql-test/suite/sys_vars/t/old_alter_table_basic.test +++ b/mysql-test/suite/sys_vars/t/old_alter_table_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-20 OBN - added check of I_S values after variable value changed +# + SET @start_global_value = @@global.old_alter_table; SELECT @start_global_value; @@ -15,9 +20,13 @@ select * from information_schema.session_variables where variable_name='old_alte # show that it's writable # set global old_alter_table=1; -select @@global.old_alter_table; set session old_alter_table=ON; +select @@global.old_alter_table; select @@session.old_alter_table; +show global variables like 'old_alter_table'; +show session variables like 'old_alter_table'; +select * from information_schema.global_variables where variable_name='old_alter_table'; +select * from information_schema.session_variables where variable_name='old_alter_table'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/optimizer_switch_basic.test b/mysql-test/suite/sys_vars/t/optimizer_switch_basic.test index 32a77c90b34..4267b3726aa 100644 --- a/mysql-test/suite/sys_vars/t/optimizer_switch_basic.test +++ b/mysql-test/suite/sys_vars/t/optimizer_switch_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-20 OBN Added check for I_S values after variable value changed +# + SET @start_global_value = @@global.optimizer_switch; SELECT @start_global_value; @@ -15,13 +20,17 @@ select * from information_schema.session_variables where variable_name='optimize # show that it's writable # set global optimizer_switch=10; -select @@global.optimizer_switch; set session optimizer_switch=5; +select @@global.optimizer_switch; select @@session.optimizer_switch; set global optimizer_switch="index_merge_sort_union=on"; -select @@global.optimizer_switch; set session optimizer_switch="index_merge=off"; +select @@global.optimizer_switch; select @@session.optimizer_switch; +show global variables like 'optimizer_switch'; +show session variables like 'optimizer_switch'; +select * from information_schema.global_variables where variable_name='optimizer_switch'; +select * from information_schema.session_variables where variable_name='optimizer_switch'; set session optimizer_switch="default"; select @@session.optimizer_switch; diff --git a/mysql-test/suite/sys_vars/t/profiling_basic.test b/mysql-test/suite/sys_vars/t/profiling_basic.test index aef56e50900..da54d5a207d 100644 --- a/mysql-test/suite/sys_vars/t/profiling_basic.test +++ b/mysql-test/suite/sys_vars/t/profiling_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-20 OBN - Added check for I_S values after variable value change +# + --source include/have_profiling.inc SET @start_global_value = @@global.profiling; @@ -17,9 +22,21 @@ select * from information_schema.session_variables where variable_name='profilin # show that it's writable # set global profiling=1; -select @@global.profiling; set session profiling=ON; +select @@global.profiling; select @@session.profiling; +show global variables like 'profiling'; +show session variables like 'profiling'; +select * from information_schema.global_variables where variable_name='profiling'; +select * from information_schema.session_variables where variable_name='profiling'; +set global profiling=0; +set session profiling=OFF; +select @@global.profiling; +select @@session.profiling; +show global variables like 'profiling'; +show session variables like 'profiling'; +select * from information_schema.global_variables where variable_name='profiling'; +select * from information_schema.session_variables where variable_name='profiling'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/profiling_history_size_basic.test b/mysql-test/suite/sys_vars/t/profiling_history_size_basic.test index 01d3533be3d..26fdc55328b 100644 --- a/mysql-test/suite/sys_vars/t/profiling_history_size_basic.test +++ b/mysql-test/suite/sys_vars/t/profiling_history_size_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-20 OBN Added check for variable and I_S values after incorrect change attempt +# + --source include/have_profiling.inc SET @start_global_value = @@global.profiling_history_size; @@ -17,9 +22,13 @@ select * from information_schema.session_variables where variable_name='profilin # show that it's writable # set global profiling_history_size=10; -select @@global.profiling_history_size; set session profiling_history_size=20; +select @@global.profiling_history_size; select @@session.profiling_history_size; +show global variables like 'profiling_history_size'; +show session variables like 'profiling_history_size'; +select * from information_schema.global_variables where variable_name='profiling_history_size'; +select * from information_schema.session_variables where variable_name='profiling_history_size'; # # incorrect assignments diff --git a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test index a948f2a8ff0..0722b42099d 100644 --- a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test +++ b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test @@ -2,21 +2,37 @@ # # exists as a session only # +# 2010-01-20 OBN - Added check for session I_S values being equal to variable value +# - Added check for session variable value being numberic +# + --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@global.pseudo_thread_id; -select @@session.pseudo_thread_id=0; + +# Check the variable has a valid numeric value (assumed to be less then 10000) +select @@session.pseudo_thread_id between 1 and 1000; + +--echo should be empty show global variables like 'pseudo_thread_id'; + +# Check that shows returns a value (can't confirm the actual one) --replace_column 2 # show session variables like 'pseudo_thread_id'; + +# Global I_S variable is empty +--echo should be empty select * from information_schema.global_variables where variable_name='pseudo_thread_id'; ---replace_column 2 # -select * from information_schema.session_variables where variable_name='pseudo_thread_id'; + +# Check that I_S value is same as variable +select @@session.pseudo_thread_id = variable_value from information_schema.session_variables where variable_name='pseudo_thread_id'; # # show that it's writable # -set session pseudo_thread_id=1; +set session pseudo_thread_id=42; select @@session.pseudo_thread_id; +select * from information_schema.global_variables where variable_name='pseudo_thread_id'; +select variable_value from information_schema.session_variables where variable_name='pseudo_thread_id'; --error ER_LOCAL_VARIABLE set global pseudo_thread_id=1; diff --git a/mysql-test/suite/sys_vars/t/rand_seed1_basic.test b/mysql-test/suite/sys_vars/t/rand_seed1_basic.test index 79c946a3d2f..3745d2fcb1e 100644 --- a/mysql-test/suite/sys_vars/t/rand_seed1_basic.test +++ b/mysql-test/suite/sys_vars/t/rand_seed1_basic.test @@ -2,6 +2,8 @@ # # exists as a session only # +# 2010-01-20 OBN - Added check for I_S value after variable value change +# --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@global.rand_seed1; select @@session.rand_seed1; @@ -11,10 +13,12 @@ select * from information_schema.global_variables where variable_name='rand_seed select * from information_schema.session_variables where variable_name='rand_seed1'; # -# show that it's writable +# show that it's writable (note value can be set but not read - returned value is zero) # set session rand_seed1=1; select @@session.rand_seed1; +select * from information_schema.global_variables where variable_name='rand_seed1'; +select * from information_schema.session_variables where variable_name='rand_seed1'; --error ER_LOCAL_VARIABLE set global rand_seed1=1; diff --git a/mysql-test/suite/sys_vars/t/rand_seed2_basic.test b/mysql-test/suite/sys_vars/t/rand_seed2_basic.test index 18e2a62557c..7a5abcd340b 100644 --- a/mysql-test/suite/sys_vars/t/rand_seed2_basic.test +++ b/mysql-test/suite/sys_vars/t/rand_seed2_basic.test @@ -2,6 +2,9 @@ # # exists as a session only # +# +# 2010-01-20 OBN - Added check for I_S value after variable value change +# --error ER_INCORRECT_GLOBAL_LOCAL_VAR select @@global.rand_seed2; select @@session.rand_seed2; @@ -11,10 +14,12 @@ select * from information_schema.global_variables where variable_name='rand_seed select * from information_schema.session_variables where variable_name='rand_seed2'; # -# show that it's writable +# show that it's writable (note value can be set but not read - returned value is zero) # set session rand_seed2=1; select @@session.rand_seed2; +select * from information_schema.global_variables where variable_name='rand_seed2'; +select * from information_schema.session_variables where variable_name='rand_seed2'; --error ER_LOCAL_VARIABLE set global rand_seed2=1; diff --git a/mysql-test/suite/sys_vars/t/relay_log_recovery_basic.test b/mysql-test/suite/sys_vars/t/relay_log_recovery_basic.test index 57c28468bd1..a6f218a59ae 100644 --- a/mysql-test/suite/sys_vars/t/relay_log_recovery_basic.test +++ b/mysql-test/suite/sys_vars/t/relay_log_recovery_basic.test @@ -1,3 +1,9 @@ + + +# +# 2010-01-10 - Added check for I_S values aver variable value change +# + --source include/not_embedded.inc SET @start_global_value = @@global.relay_log_recovery; @@ -19,8 +25,12 @@ select * from information_schema.session_variables where variable_name='relay_lo # set global relay_log_recovery=1; select @@global.relay_log_recovery; +select * from information_schema.global_variables where variable_name='relay_log_recovery'; +select * from information_schema.session_variables where variable_name='relay_log_recovery'; set global relay_log_recovery=OFF; select @@global.relay_log_recovery; +select * from information_schema.global_variables where variable_name='relay_log_recovery'; +select * from information_schema.session_variables where variable_name='relay_log_recovery'; --error ER_GLOBAL_VARIABLE set session relay_log_recovery=1; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test new file mode 100644 index 00000000000..5aea6e165ea --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test @@ -0,0 +1,62 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; +select @@global.rpl_semi_sync_master_enabled; +SET @start_global_value = @@global.rpl_semi_sync_master_enabled; + +select @@global.rpl_semi_sync_master_enabled in (0,1); +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_enabled; +show global variables like 'rpl_semi_sync_master_enabled'; +show session variables like 'rpl_semi_sync_master_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; + +# +# show that it's writable +# +set global rpl_semi_sync_master_enabled=0; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_enabled=0; +select @@global.rpl_semi_sync_master_enabled; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_enabled; +show global variables like 'rpl_semi_sync_master_enabled'; +show session variables like 'rpl_semi_sync_master_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; +set global rpl_semi_sync_master_enabled=1; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_enabled=1; +select @@global.rpl_semi_sync_master_enabled; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_enabled; +show global variables like 'rpl_semi_sync_master_enabled'; +show session variables like 'rpl_semi_sync_master_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_enabled'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_enabled=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_enabled=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global rpl_semi_sync_master_enabled="some text"; + + +# +# Cleanup +# +SET @@global.rpl_semi_sync_master_enabled = @start_global_value; +select @@global.rpl_semi_sync_master_enabled; +UNINSTALL PLUGIN rpl_semi_sync_master; + diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test new file mode 100644 index 00000000000..6c4aae8e3bf --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test @@ -0,0 +1,52 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; +select @@global.rpl_semi_sync_master_timeout; +SET @start_global_value = @@global.rpl_semi_sync_master_timeout; + +--echo Assuming value will not be more then 100 sec +select @@global.rpl_semi_sync_master_timeout between 1 and 100000; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_timeout; +show global variables like 'rpl_semi_sync_master_timeout'; +show session variables like 'rpl_semi_sync_master_timeout'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_timeout'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_timeout'; + +# +# show that it's writable +# +set global rpl_semi_sync_master_timeout=42; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_timeout=99; +select @@global.rpl_semi_sync_master_timeout; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_timeout; +show global variables like 'rpl_semi_sync_master_timeout'; +show session variables like 'rpl_semi_sync_master_timeout'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_timeout'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_timeout'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_timeout=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_timeout=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_timeout="some text"; + + +# +# Cleanup +# +SET @@global.rpl_semi_sync_master_timeout = @start_global_value; +select @@global.rpl_semi_sync_master_timeout; +UNINSTALL PLUGIN rpl_semi_sync_master; + diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test new file mode 100644 index 00000000000..c37248ffa9a --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test @@ -0,0 +1,60 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; +select @@global.rpl_semi_sync_master_trace_level; +SET @start_global_value = @@global.rpl_semi_sync_master_trace_level; + +select @@global.rpl_semi_sync_master_trace_level in (1,16,32,64); +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_trace_level; +show global variables like 'rpl_semi_sync_master_trace_level'; +show session variables like 'rpl_semi_sync_master_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; + +# +# show that it's writable +# +set global rpl_semi_sync_master_trace_level=16; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_trace_level=99; +select @@global.rpl_semi_sync_master_trace_level; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_trace_level; +show global variables like 'rpl_semi_sync_master_trace_level'; +show session variables like 'rpl_semi_sync_master_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; + +--echo NOTE: Value can also be set to values that are combinations of values +set global rpl_semi_sync_master_trace_level=42; +select @@global.rpl_semi_sync_master_trace_level; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_trace_level; +show global variables like 'rpl_semi_sync_master_trace_level'; +show session variables like 'rpl_semi_sync_master_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_trace_level'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_trace_level=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_trace_level=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_trace_level="some text"; + +# +# Cleanup +# +SET @@global.rpl_semi_sync_master_trace_level = @start_global_value; +select @@global.rpl_semi_sync_master_trace_level; +UNINSTALL PLUGIN rpl_semi_sync_master; + diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test new file mode 100644 index 00000000000..a90024b8961 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test @@ -0,0 +1,62 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; +select @@global.rpl_semi_sync_master_wait_no_slave; +SET @start_global_value = @@global.rpl_semi_sync_master_wait_no_slave; + +select @@global.rpl_semi_sync_master_wait_no_slave in (0,1); +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_wait_no_slave; +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; + +# +# show that it's writable +# +set global rpl_semi_sync_master_wait_no_slave=0; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_wait_no_slave=0; +select @@global.rpl_semi_sync_master_wait_no_slave; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_wait_no_slave; +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +set global rpl_semi_sync_master_wait_no_slave=1; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_master_wait_no_slave=1; +select @@global.rpl_semi_sync_master_wait_no_slave; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_master_wait_no_slave; +show global variables like 'rpl_semi_sync_master_wait_no_slave'; +show session variables like 'rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_master_wait_no_slave'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_wait_no_slave=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_master_wait_no_slave=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global rpl_semi_sync_master_wait_no_slave="some text"; + + +# +# Cleanup +# +SET @@global.rpl_semi_sync_master_wait_no_slave = @start_global_value; +select @@global.rpl_semi_sync_master_wait_no_slave; +UNINSTALL PLUGIN rpl_semi_sync_master; + diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test new file mode 100644 index 00000000000..5dca63d5e2d --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test @@ -0,0 +1,63 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; +select @@global.rpl_semi_sync_slave_enabled; +SET @start_global_value = @@global.rpl_semi_sync_slave_enabled; + +select @@global.rpl_semi_sync_slave_enabled in (0,1); +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_enabled; +show global variables like 'rpl_semi_sync_slave_enabled'; +show session variables like 'rpl_semi_sync_slave_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; + +# +# show that it's writable +# +set global rpl_semi_sync_slave_enabled=0; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_slave_enabled=0; +select @@global.rpl_semi_sync_slave_enabled; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_enabled; +show global variables like 'rpl_semi_sync_slave_enabled'; +show session variables like 'rpl_semi_sync_slave_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; +set global rpl_semi_sync_slave_enabled=1; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_slave_enabled=1; +select @@global.rpl_semi_sync_slave_enabled; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_enabled; +show global variables like 'rpl_semi_sync_slave_enabled'; +show session variables like 'rpl_semi_sync_slave_enabled'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_enabled'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_enabled'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_slave_enabled=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_slave_enabled=1e1; +--error ER_WRONG_VALUE_FOR_VAR +set global rpl_semi_sync_slave_enabled="some text"; +--error ER_WRONG_VALUE_FOR_VAR + + +# +# Cleanup +# +SET @@global.rpl_semi_sync_slave_enabled = @start_global_value; +select @@global.rpl_semi_sync_slave_enabled; +UNINSTALL PLUGIN rpl_semi_sync_slave; + diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic-master.opt b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic-master.opt new file mode 100644 index 00000000000..58029d28ace --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic-master.opt @@ -0,0 +1 @@ +$SEMISYNC_PLUGIN_OPT diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test new file mode 100644 index 00000000000..afac5244eb2 --- /dev/null +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test @@ -0,0 +1,60 @@ + +# +# exists as a global only +# +# 2010-01-21 OBN - Added +# +source include/have_semisync_plugin.inc; +eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; +select @@global.rpl_semi_sync_slave_trace_level; +SET @start_global_value = @@global.rpl_semi_sync_slave_trace_level; + +select @@global.rpl_semi_sync_slave_trace_level in (1,16,32,64); +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_trace_level; +show global variables like 'rpl_semi_sync_slave_trace_level'; +show session variables like 'rpl_semi_sync_slave_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; + +# +# show that it's writable +# +set global rpl_semi_sync_slave_trace_level=16; +--error ER_GLOBAL_VARIABLE +set session rpl_semi_sync_slave_trace_level=99; +select @@global.rpl_semi_sync_slave_trace_level; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_trace_level; +show global variables like 'rpl_semi_sync_slave_trace_level'; +show session variables like 'rpl_semi_sync_slave_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; + +--echo NOTE: Value can also be set to values that are combinations of values +set global rpl_semi_sync_slave_trace_level=42; +select @@global.rpl_semi_sync_slave_trace_level; +--error ER_INCORRECT_GLOBAL_LOCAL_VAR +select @@session.rpl_semi_sync_slave_trace_level; +show global variables like 'rpl_semi_sync_slave_trace_level'; +show session variables like 'rpl_semi_sync_slave_trace_level'; +select * from information_schema.global_variables where variable_name='rpl_semi_sync_slave_trace_level'; +select * from information_schema.session_variables where variable_name='rpl_semi_sync_slave_trace_level'; + +# +# incorrect types +# +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_slave_trace_level=1.1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_slave_trace_level=1e1; +--error ER_WRONG_TYPE_FOR_VAR +set global rpl_semi_sync_slave_trace_level="some text"; + +# +# Cleanup +# +SET @@global.rpl_semi_sync_slave_trace_level = @start_global_value; +select @@global.rpl_semi_sync_slave_trace_level; +UNINSTALL PLUGIN rpl_semi_sync_slave; + diff --git a/mysql-test/suite/sys_vars/t/sql_log_update_basic.test b/mysql-test/suite/sys_vars/t/sql_log_update_basic.test index c48840d4a81..9b9f6f375b6 100644 --- a/mysql-test/suite/sys_vars/t/sql_log_update_basic.test +++ b/mysql-test/suite/sys_vars/t/sql_log_update_basic.test @@ -1,3 +1,9 @@ + +# +# 2010-01-20 OBN - Added check of I_S tables after variable value changes. +# - Added value change to ON/OFF to ensure change of current value +# + --source include/have_profiling.inc SET @start_global_value = @@global.sql_log_update; @@ -17,9 +23,21 @@ select * from information_schema.session_variables where variable_name='sql_log_ # show that it's writable # set global sql_log_update=1; -select @@global.sql_log_update; set session sql_log_update=ON; +select @@global.sql_log_update; select @@session.sql_log_update; +show global variables like 'sql_log_update'; +show session variables like 'sql_log_update'; +select * from information_schema.global_variables where variable_name='sql_log_update'; +select * from information_schema.session_variables where variable_name='sql_log_update'; +set global sql_log_update=0; +set session sql_log_update=OFF; +select @@global.sql_log_update; +select @@session.sql_log_update; +show global variables like 'sql_log_update'; +show session variables like 'sql_log_update'; +select * from information_schema.global_variables where variable_name='sql_log_update'; +select * from information_schema.session_variables where variable_name='sql_log_update'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/sql_max_join_size_basic.test b/mysql-test/suite/sys_vars/t/sql_max_join_size_basic.test index bafa11379aa..9a72846b29c 100644 --- a/mysql-test/suite/sys_vars/t/sql_max_join_size_basic.test +++ b/mysql-test/suite/sys_vars/t/sql_max_join_size_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-20 OBN - Added check of I_S values after variable value change +# + SET @start_global_value = @@global.sql_max_join_size; SELECT @start_global_value; @@ -15,9 +20,13 @@ select * from information_schema.session_variables where variable_name='sql_max_ # show that it's writable # set global sql_max_join_size=10; -select @@global.sql_max_join_size; set session sql_max_join_size=20; +select @@global.sql_max_join_size; select @@session.sql_max_join_size; +show global variables like 'sql_max_join_size'; +show session variables like 'sql_max_join_size'; +select * from information_schema.global_variables where variable_name='sql_max_join_size'; +select * from information_schema.session_variables where variable_name='sql_max_join_size'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/sql_select_limit_basic.test b/mysql-test/suite/sys_vars/t/sql_select_limit_basic.test index 0b941d25f42..c6bc5962205 100644 --- a/mysql-test/suite/sys_vars/t/sql_select_limit_basic.test +++ b/mysql-test/suite/sys_vars/t/sql_select_limit_basic.test @@ -1,3 +1,8 @@ + +# +# 2010-01-10 OBN - Added check for I_S values after change of variable value +# + SET @start_global_value = @@global.sql_select_limit; SELECT @start_global_value; @@ -15,9 +20,13 @@ select * from information_schema.session_variables where variable_name='sql_sele # show that it's writable # set global sql_select_limit=10; -select @@global.sql_select_limit; set session sql_select_limit=20; +select @@global.sql_select_limit; select @@session.sql_select_limit; +show global variables like 'sql_select_limit'; +show session variables like 'sql_select_limit'; +select * from information_schema.global_variables where variable_name='sql_select_limit'; +select * from information_schema.session_variables where variable_name='sql_select_limit'; # # incorrect types diff --git a/mysql-test/suite/sys_vars/t/thread_cache_size_basic.test b/mysql-test/suite/sys_vars/t/thread_cache_size_basic.test index 48a4c0797e5..22aaff6d426 100644 --- a/mysql-test/suite/sys_vars/t/thread_cache_size_basic.test +++ b/mysql-test/suite/sys_vars/t/thread_cache_size_basic.test @@ -1,4 +1,8 @@ +# +# 2010-01-20 OBN - Added check of I_S values after variable value change +# + SET @start_global_value = @@global.thread_cache_size; SELECT @start_global_value; @@ -18,6 +22,8 @@ select * from information_schema.session_variables where variable_name='thread_c # set global thread_cache_size=1; select @@global.thread_cache_size; +select * from information_schema.global_variables where variable_name='thread_cache_size'; +select * from information_schema.session_variables where variable_name='thread_cache_size'; --error ER_GLOBAL_VARIABLE set session thread_cache_size=1; From e9da37b6e77fee90f3925fedc722967d09ba8d64 Mon Sep 17 00:00:00 2001 From: Omer BarNir Date: Wed, 3 Feb 2010 09:11:16 -0800 Subject: [PATCH 2/3] Fixes to PB failiurs mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result: Uodated result file mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test: Added code to explain the failiure mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test: Added code to handle diff result outpt in windows (dll vs. so) mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test: Added code to handle diff result outpt in windows (dll vs. so) mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test: Added code to handle diff result outpt in windows (dll vs. so) mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test: Added code to handle diff result outpt in windows (dll vs. so) mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test: Added code to handle diff result outpt in windows (dll vs. so) mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test: Added code to handle diff result outpt in windows (dll vs. so) --- mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result | 7 +++++-- mysql-test/suite/sys_vars/t/all_vars.test | 3 +++ mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test | 3 ++- .../sys_vars/t/rpl_semi_sync_master_enabled_basic.test | 2 ++ .../sys_vars/t/rpl_semi_sync_master_timeout_basic.test | 2 ++ .../sys_vars/t/rpl_semi_sync_master_trace_level_basic.test | 2 ++ .../t/rpl_semi_sync_master_wait_no_slave_basic.test | 2 ++ .../sys_vars/t/rpl_semi_sync_slave_enabled_basic.test | 2 ++ .../sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test | 2 ++ 9 files changed, 22 insertions(+), 3 deletions(-) diff --git a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result index 6b0a8899560..4457d2a0075 100644 --- a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result +++ b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result @@ -1,8 +1,11 @@ select @@global.pseudo_thread_id; ERROR HY000: Variable 'pseudo_thread_id' is a SESSION variable -select @@session.pseudo_thread_id between 1 and 1000; -@@session.pseudo_thread_id between 1 and 1000 +select @@session.pseudo_thread_id between 1 and 10000; +@@session.pseudo_thread_id between 1 and 10000 1 +select @@session.pseudo_thread_id; +@@session.pseudo_thread_id +2 should be empty show global variables like 'pseudo_thread_id'; Variable_name Value diff --git a/mysql-test/suite/sys_vars/t/all_vars.test b/mysql-test/suite/sys_vars/t/all_vars.test index 0e831319898..e9e7e16687a 100644 --- a/mysql-test/suite/sys_vars/t/all_vars.test +++ b/mysql-test/suite/sys_vars/t/all_vars.test @@ -24,7 +24,10 @@ if (`SELECT @@have_dynamic_loading = 'YES' AND LENGTH('$SEMISYNC_MASTER_PLUGIN') > 0`) { --disable_query_log + # The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' + --replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; + --replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; --enable_query_log } diff --git a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test index 0722b42099d..4f5e7bcf23e 100644 --- a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test +++ b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test @@ -10,7 +10,8 @@ select @@global.pseudo_thread_id; # Check the variable has a valid numeric value (assumed to be less then 10000) -select @@session.pseudo_thread_id between 1 and 1000; +select @@session.pseudo_thread_id between 1 and 10000; +select @@session.pseudo_thread_id; --echo should be empty show global variables like 'pseudo_thread_id'; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test index 5aea6e165ea..749695e035c 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_enabled_basic.test @@ -6,6 +6,8 @@ # # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; select @@global.rpl_semi_sync_master_enabled; SET @start_global_value = @@global.rpl_semi_sync_master_enabled; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test index 6c4aae8e3bf..16389c23d54 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_timeout_basic.test @@ -5,6 +5,8 @@ # 2010-01-21 OBN - Added # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; select @@global.rpl_semi_sync_master_timeout; SET @start_global_value = @@global.rpl_semi_sync_master_timeout; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test index c37248ffa9a..c23aa1da688 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_trace_level_basic.test @@ -5,6 +5,8 @@ # 2010-01-21 OBN - Added # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; select @@global.rpl_semi_sync_master_trace_level; SET @start_global_value = @@global.rpl_semi_sync_master_trace_level; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test index a90024b8961..9686a0e0d9a 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_master_wait_no_slave_basic.test @@ -6,6 +6,8 @@ # # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN'; select @@global.rpl_semi_sync_master_wait_no_slave; SET @start_global_value = @@global.rpl_semi_sync_master_wait_no_slave; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test index 5dca63d5e2d..0bb16cfd38e 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_enabled_basic.test @@ -6,6 +6,8 @@ # # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; select @@global.rpl_semi_sync_slave_enabled; SET @start_global_value = @@global.rpl_semi_sync_slave_enabled; diff --git a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test index afac5244eb2..2bdf09f2a7f 100644 --- a/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test +++ b/mysql-test/suite/sys_vars/t/rpl_semi_sync_slave_trace_level_basic.test @@ -5,6 +5,8 @@ # 2010-01-21 OBN - Added # source include/have_semisync_plugin.inc; +# The following is to prevent a mis-match on windows that has the name of of the lib ending with 'dll' +--replace_regex /\.dll/.so/ eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN'; select @@global.rpl_semi_sync_slave_trace_level; SET @start_global_value = @@global.rpl_semi_sync_slave_trace_level; From eadf1586b8d519c22a9c038cdda16b212e33021a Mon Sep 17 00:00:00 2001 From: Omer BarNir Date: Thu, 4 Feb 2010 12:14:51 -0800 Subject: [PATCH 3/3] Corrections to pseudi_thread_id_basic test (WL4738) mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result: Updated result file mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test: Removed specific thread_id result vaue used for debuging PB2 issue --- mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result | 3 --- mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test | 1 - 2 files changed, 4 deletions(-) diff --git a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result index 4457d2a0075..ee6169a9e35 100644 --- a/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result +++ b/mysql-test/suite/sys_vars/r/pseudo_thread_id_basic.result @@ -3,9 +3,6 @@ ERROR HY000: Variable 'pseudo_thread_id' is a SESSION variable select @@session.pseudo_thread_id between 1 and 10000; @@session.pseudo_thread_id between 1 and 10000 1 -select @@session.pseudo_thread_id; -@@session.pseudo_thread_id -2 should be empty show global variables like 'pseudo_thread_id'; Variable_name Value diff --git a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test index 4f5e7bcf23e..fef3e906869 100644 --- a/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test +++ b/mysql-test/suite/sys_vars/t/pseudo_thread_id_basic.test @@ -11,7 +11,6 @@ select @@global.pseudo_thread_id; # Check the variable has a valid numeric value (assumed to be less then 10000) select @@session.pseudo_thread_id between 1 and 10000; -select @@session.pseudo_thread_id; --echo should be empty show global variables like 'pseudo_thread_id';