From a876121d24a19340db508f74b1582955c2a168b0 Mon Sep 17 00:00:00 2001 From: Monty Date: Fri, 30 Oct 2020 15:33:18 +0200 Subject: [PATCH 01/15] MDEV-23824 SIGSEGV in end_io_cache on REPAIR LOCAL TABLE for Aria table Bugs fixed: - prepare_for_repair() didn't close all open files if table opened failed because of out-of-memory - If dd_recreate_table() failed, the data file was not properly restored from it's temporary name - Aria repair initializing code didn't properly clear all used structs before calling error, which caused crashed in memory-free calls. - maria_delete_table() didn't register if table open failed. This could calls my_error() to be called without returning 1 to the caller, which cased failures in my_ok() Note when merging to 10.5: - Remove the #if MYSQL_VERSION from sql_admin.cc --- mysql-test/suite/maria/repair.result | 16 ++++++++++ mysql-test/suite/maria/repair.test | 11 +++++++ sql/sql_admin.cc | 45 +++++++++++++++++++--------- storage/maria/ma_check.c | 34 ++++++++++++++------- storage/maria/ma_delete_table.c | 9 +++++- storage/maria/ma_open.c | 2 +- 6 files changed, 91 insertions(+), 26 deletions(-) diff --git a/mysql-test/suite/maria/repair.result b/mysql-test/suite/maria/repair.result index 6bb9e1b5b9e..296f251aa36 100644 --- a/mysql-test/suite/maria/repair.result +++ b/mysql-test/suite/maria/repair.result @@ -22,3 +22,19 @@ i 1 UNLOCK TABLES; DROP TABLE t1; +# +# MDEV-23824 SIGSEGV in end_io_cache on REPAIR LOCAL TABLE for Aria table +# +CREATE TABLE t1 (i INT) ENGINE=Aria; +INSERT INTO t1 VALUES (1); +SET max_session_mem_used=50000; +REPAIR LOCAL TABLE t1 USE_FRM; +Table Op Msg_type Msg_text +t1 repair error Failed to open partially repaired table +Warnings: +Error 1290 The MariaDB server is running with the --max-thread-mem-used=50000 option so it cannot execute this statement +REPAIR LOCAL TABLE t1; +Table Op Msg_type Msg_text +test.t1 repair Error The MariaDB server is running with the --max-thread-mem-used=50000 option so it cannot execute this statement +test.t1 repair error Corrupt +DROP TABLE t1; diff --git a/mysql-test/suite/maria/repair.test b/mysql-test/suite/maria/repair.test index 2f713950d3e..9603a949f9b 100644 --- a/mysql-test/suite/maria/repair.test +++ b/mysql-test/suite/maria/repair.test @@ -22,3 +22,14 @@ SELECT * FROM INFORMATION_SCHEMA.TABLES; SELECT * FROM t1; UNLOCK TABLES; DROP TABLE t1; + +--echo # +--echo # MDEV-23824 SIGSEGV in end_io_cache on REPAIR LOCAL TABLE for Aria table +--echo # + +CREATE TABLE t1 (i INT) ENGINE=Aria; +INSERT INTO t1 VALUES (1); +SET max_session_mem_used=50000; +REPAIR LOCAL TABLE t1 USE_FRM; +REPAIR LOCAL TABLE t1; +DROP TABLE t1; diff --git a/sql/sql_admin.cc b/sql/sql_admin.cc index 89ef6d7793f..8e956eb0f8c 100644 --- a/sql/sql_admin.cc +++ b/sql/sql_admin.cc @@ -91,10 +91,10 @@ static int send_check_errmsg(THD *thd, TABLE_LIST* table, static int prepare_for_repair(THD *thd, TABLE_LIST *table_list, HA_CHECK_OPT *check_opt) { - int error= 0; + int error= 0, create_error= 0; TABLE tmp_table, *table; TABLE_LIST *pos_in_locked_tables= 0; - TABLE_SHARE *share; + TABLE_SHARE *share= 0; bool has_mdl_lock= FALSE; char from[FN_REFLEN],tmp[FN_REFLEN+32]; const char **ext; @@ -207,6 +207,23 @@ static int prepare_for_repair(THD *thd, TABLE_LIST *table_list, HA_EXTRA_NOT_USED, NULL); table_list->table= 0; } + else + { + /* + Table open failed, maybe because we run out of memory. + Close all open tables and relaese all MDL locks + */ +#if MYSQL_VERSION < 100500 + tdc_remove_table(thd, TDC_RT_REMOVE_UNUSED, + table->s->db.str, table->s->table_name.str, + TRUE); +#else + tdc_release_share(share); + share->tdc->flush(thd, true); + share= 0; +#endif + } + /* After this point we have an exclusive metadata lock on our table in both cases when table was successfully open in mysql_admin_table() @@ -220,11 +237,8 @@ static int prepare_for_repair(THD *thd, TABLE_LIST *table_list, goto end; } if (dd_recreate_table(thd, table_list->db.str, table_list->table_name.str)) - { - error= send_check_errmsg(thd, table_list, "repair", - "Failed generating table from .frm file"); - goto end; - } + create_error= send_check_errmsg(thd, table_list, "repair", + "Failed generating table from .frm file"); /* 'FALSE' for 'using_transactions' means don't postpone invalidation till the end of a transaction, but do it @@ -237,6 +251,8 @@ static int prepare_for_repair(THD *thd, TABLE_LIST *table_list, "Failed restoring .MYD file"); goto end; } + if (create_error) + goto end; if (thd->locked_tables_list.locked_tables()) { @@ -264,7 +280,8 @@ end: if (table == &tmp_table) { closefrm(table); - tdc_release_share(table->s); + if (share) + tdc_release_share(share); } /* In case of a temporary table there will be no metadata lock. */ if (unlikely(error) && has_mdl_lock) @@ -592,6 +609,12 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables, #endif DBUG_PRINT("admin", ("table: %p", table->table)); + if (table->schema_table) + { + result_code= HA_ADMIN_NOT_IMPLEMENTED; + goto send_result; + } + if (prepare_func) { DBUG_PRINT("admin", ("calling prepare_func")); @@ -650,12 +673,6 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables, goto send_result; } - if (table->schema_table) - { - result_code= HA_ADMIN_NOT_IMPLEMENTED; - goto send_result; - } - if ((table->table->db_stat & HA_READ_ONLY) && open_for_modify) { /* purecov: begin inspected */ diff --git a/storage/maria/ma_check.c b/storage/maria/ma_check.c index 20f8eca2828..0f4d79032f8 100644 --- a/storage/maria/ma_check.c +++ b/storage/maria/ma_check.c @@ -2344,6 +2344,14 @@ static int initialize_variables_for_repair(HA_CHECK *param, { MARIA_SHARE *share= info->s; + /* + We have to clear these variables first, as the cleanup-in-case-of-error + handling may touch these. + */ + bzero((char*) sort_info, sizeof(*sort_info)); + bzero((char*) sort_param, sizeof(*sort_param)); + bzero(&info->rec_cache, sizeof(info->rec_cache)); + if (share->data_file_type == NO_RECORD) { _ma_check_print_error(param, @@ -2358,9 +2366,6 @@ static int initialize_variables_for_repair(HA_CHECK *param, if (share->lock.update_status) (*share->lock.update_status)(info); - bzero((char*) sort_info, sizeof(*sort_info)); - bzero((char*) sort_param, sizeof(*sort_param)); - param->testflag|= T_REP; /* for easy checking */ if (share->options & (HA_OPTION_CHECKSUM | HA_OPTION_COMPRESS_RECORD)) param->testflag|= T_CALC_CHECKSUM; @@ -2388,7 +2393,6 @@ static int initialize_variables_for_repair(HA_CHECK *param, set_data_file_type(sort_info, info->s); sort_info->org_data_file_type= share->data_file_type; - bzero(&info->rec_cache, sizeof(info->rec_cache)); info->rec_cache.file= info->dfile.file; info->update= (short) (HA_STATE_CHANGED | HA_STATE_ROW_CHANGED); @@ -2869,9 +2873,13 @@ err: _ma_reset_state(info); end_io_cache(¶m->read_cache); - end_io_cache(&sort_info.new_info->rec_cache); + if (sort_info.new_info) + { + end_io_cache(&sort_info.new_info->rec_cache); + sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); + } info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); - sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); + sort_param.sort_info->info->in_check_table= 0; /* this below could fail, shouldn't we detect error? */ if (got_error) @@ -4086,10 +4094,13 @@ err: maria_scan_end(sort_info.info); _ma_reset_state(info); - end_io_cache(&sort_info.new_info->rec_cache); + if (sort_info.new_info) + { + end_io_cache(&sort_info.new_info->rec_cache); + sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); + } end_io_cache(¶m->read_cache); info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); - sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); if (got_error) { if (! param->error_printed) @@ -4618,10 +4629,13 @@ err: the share by remove_io_thread() or it was not yet started (if the error happend before creating the thread). */ - end_io_cache(&sort_info.new_info->rec_cache); + if (sort_info.new_info) + { + end_io_cache(&sort_info.new_info->rec_cache); + sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); + } end_io_cache(¶m->read_cache); info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); - sort_info.new_info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED); /* Destroy the new data cache in case of non-quick repair. All slave threads did either detach from the share by remove_io_thread() diff --git a/storage/maria/ma_delete_table.c b/storage/maria/ma_delete_table.c index fee001df1e1..0c78476ad44 100644 --- a/storage/maria/ma_delete_table.c +++ b/storage/maria/ma_delete_table.c @@ -30,6 +30,7 @@ int maria_delete_table(const char *name) { MARIA_HA *info; myf sync_dir; + int got_error= 0, error; DBUG_ENTER("maria_delete_table"); #ifdef EXTRA_DEBUG @@ -41,9 +42,13 @@ int maria_delete_table(const char *name) Unfortunately it is necessary to open the table just to check this. We use 'open_for_repair' to be able to open even a crashed table. */ + my_errno= 0; if (!(info= maria_open(name, O_RDONLY, HA_OPEN_FOR_REPAIR))) { sync_dir= 0; + /* Ignore not found errors and wrong symlink errors */ + if (my_errno != ENOENT && my_errno != HA_WRONG_CREATE_OPTION) + got_error= my_errno;; } else { @@ -78,7 +83,9 @@ int maria_delete_table(const char *name) DBUG_RETURN(1); } - DBUG_RETURN(maria_delete_table_files(name, 0, sync_dir)); + if (!(error= maria_delete_table_files(name, 0, sync_dir))) + error= got_error; + DBUG_RETURN(error); } diff --git a/storage/maria/ma_open.c b/storage/maria/ma_open.c index 226ebe8c1dd..3fa0e4293a6 100644 --- a/storage/maria/ma_open.c +++ b/storage/maria/ma_open.c @@ -1334,7 +1334,7 @@ static void setup_key_functions(register MARIA_KEYDEF *keyinfo) /** - @brief Function to save and store the header in the index file (.MYI) + @brief Function to save and store the header in the index file (.MAI) Operates under MARIA_SHARE::intern_lock if requested. Sets MARIA_SHARE::MARIA_STATE_INFO::is_of_horizon if transactional table. From 94859d985e22ff8a62300635502afa6ed2186905 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Lindstr=C3=B6m?= Date: Tue, 3 Nov 2020 08:49:10 +0200 Subject: [PATCH 02/15] Clean up wsrep.variables --- mysql-test/suite/wsrep/r/variables.result | 60 ----------------------- mysql-test/suite/wsrep/t/variables.test | 6 --- 2 files changed, 66 deletions(-) diff --git a/mysql-test/suite/wsrep/r/variables.result b/mysql-test/suite/wsrep/r/variables.result index c9c0c5af9c5..1c427b34d2b 100644 --- a/mysql-test/suite/wsrep/r/variables.result +++ b/mysql-test/suite/wsrep/r/variables.result @@ -20,66 +20,6 @@ SET GLOBAL wsrep_provider=none; # variables when using "_" # CALL mtr.add_suppression("WSREP: Could not open saved state file for reading.*"); -# wsrep -SHOW GLOBAL STATUS LIKE 'wsrep%'; -Variable_name Value -wsrep_applier_thread_count # -wsrep_apply_oooe # -wsrep_apply_oool # -wsrep_apply_window # -wsrep_causal_reads # -wsrep_cert_deps_distance # -wsrep_cert_index_size # -wsrep_cert_interval # -wsrep_cluster_conf_id # -wsrep_cluster_size # -wsrep_cluster_state_uuid # -wsrep_cluster_status # -wsrep_commit_oooe # -wsrep_commit_oool # -wsrep_commit_window # -wsrep_connected # -wsrep_debug_sync_waiters # -wsrep_flow_control_paused # -wsrep_flow_control_paused_ns # -wsrep_flow_control_recv # -wsrep_flow_control_sent # -wsrep_incoming_addresses # -wsrep_last_committed # -wsrep_local_bf_aborts # -wsrep_local_cached_downto # -wsrep_local_cert_failures # -wsrep_local_commits # -wsrep_local_index # -wsrep_local_recv_queue # -wsrep_local_recv_queue_avg # -wsrep_local_recv_queue_max # -wsrep_local_recv_queue_min # -wsrep_local_replays # -wsrep_local_send_queue # -wsrep_local_send_queue_avg # -wsrep_local_send_queue_max # -wsrep_local_send_queue_min # -wsrep_local_state # -wsrep_local_state_comment # -wsrep_local_state_uuid # -wsrep_open_connections # -wsrep_open_transactions # -wsrep_protocol_version # -wsrep_provider_name # -wsrep_provider_vendor # -wsrep_provider_version # -wsrep_ready # -wsrep_received # -wsrep_received_bytes # -wsrep_repl_data_bytes # -wsrep_repl_keys # -wsrep_repl_keys_bytes # -wsrep_repl_other_bytes # -wsrep_replicated # -wsrep_replicated_bytes # -wsrep_rollbacker_thread_count # -wsrep_thread_count # SHOW GLOBAL STATUS LIKE 'wsrep_local_state_comment'; Variable_name Value wsrep_local_state_comment # diff --git a/mysql-test/suite/wsrep/t/variables.test b/mysql-test/suite/wsrep/t/variables.test index 2556d8ede4f..5ab0eb68505 100644 --- a/mysql-test/suite/wsrep/t/variables.test +++ b/mysql-test/suite/wsrep/t/variables.test @@ -1,7 +1,6 @@ --source include/have_wsrep.inc --source include/force_restart.inc --source include/have_innodb.inc ---source include/galera_have_debug_sync.inc call mtr.add_suppression("WSREP: Initial position was provided by configuration or SST, avoiding override"); @@ -40,11 +39,6 @@ source include/check_galera_version.inc; --enable_result_log --enable_query_log ---echo # wsrep ---sorted_result ---replace_column 2 # -SHOW GLOBAL STATUS LIKE 'wsrep%'; - --replace_column 2 # SHOW GLOBAL STATUS LIKE 'wsrep_local_state_comment'; From 97f3207cf3d1a119fe3d6a56b204e5bf30cec109 Mon Sep 17 00:00:00 2001 From: Daniele Sciascia Date: Mon, 2 Nov 2020 14:18:49 +0100 Subject: [PATCH 03/15] Fix MTR test galera.galera_trigger MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Changed the test so that it does not rely on specific auto increment ids. With Galera's default wsrep_auto_increment_control setting it is not guaranteed that auto increments always start from 1. The test was occasionally failing due to result content mismatch. Reviewed-by: Jan Lindström --- .../suite/galera/r/galera_trigger.result | 44 +++++++++++++++++++ mysql-test/suite/galera/t/galera_trigger.test | 36 +++++++++++++++ 2 files changed, 80 insertions(+) diff --git a/mysql-test/suite/galera/r/galera_trigger.result b/mysql-test/suite/galera/r/galera_trigger.result index 112d3f39aa0..059f8ef13f9 100644 --- a/mysql-test/suite/galera/r/galera_trigger.result +++ b/mysql-test/suite/galera/r/galera_trigger.result @@ -30,3 +30,47 @@ id 200 DROP TRIGGER tr1; DROP TABLE t1; +connection node_1; +CREATE TABLE t1(id int not null auto_increment, value int not null, primary key (id)) engine=innodb; +CREATE TABLE t2(id int not null auto_increment, tbl varchar(64) not null, action varchar(64) not null, primary key (id)); +create trigger log_insert after insert on t1 +for each row begin +insert into t2(tbl, action) values ('t1', 'INSERT'); +end| +insert into t1(value) values (1); +insert into t1(value) values (2); +connection node_2; +set session wsrep_sync_wait=15; +insert into t1(value) values (3); +insert into t1(value) values (4); +select tbl, action from t2; +tbl action +t1 INSERT +t1 INSERT +t1 INSERT +t1 INSERT +connection node_1; +drop trigger if exists log_insert; +insert into t1(value) values (5); +select tbl, action from t2; +tbl action +t1 INSERT +t1 INSERT +t1 INSERT +t1 INSERT +connection node_2; +insert into t1(value) values (6); +select tbl, action from t2; +tbl action +t1 INSERT +t1 INSERT +t1 INSERT +t1 INSERT +connection node_1; +select tbl, action from t2; +tbl action +t1 INSERT +t1 INSERT +t1 INSERT +t1 INSERT +drop table t1, t2; diff --git a/mysql-test/suite/galera/t/galera_trigger.test b/mysql-test/suite/galera/t/galera_trigger.test index 54508583f4b..3c66b941e32 100644 --- a/mysql-test/suite/galera/t/galera_trigger.test +++ b/mysql-test/suite/galera/t/galera_trigger.test @@ -33,4 +33,40 @@ SELECT * FROM t1; DROP TRIGGER tr1; DROP TABLE t1; +# +# MDEV-23638 : DROP TRIGGER in Galera Cluster not replicating +# +--connection node_1 +CREATE TABLE t1(id int not null auto_increment, value int not null, primary key (id)) engine=innodb; +CREATE TABLE t2(id int not null auto_increment, tbl varchar(64) not null, action varchar(64) not null, primary key (id)); + +--delimiter | +create trigger log_insert after insert on t1 +for each row begin + insert into t2(tbl, action) values ('t1', 'INSERT'); +end| +--delimiter ; + +insert into t1(value) values (1); +insert into t1(value) values (2); + +--connection node_2 +set session wsrep_sync_wait=15; +insert into t1(value) values (3); +insert into t1(value) values (4); +select tbl, action from t2; + +--connection node_1 +drop trigger if exists log_insert; +insert into t1(value) values (5); +select tbl, action from t2; + +--connection node_2 +insert into t1(value) values (6); +select tbl, action from t2; + +--connection node_1 +select tbl, action from t2; + +drop table t1, t2; From 8ba641a6760075199f97d565f6634f4273091070 Mon Sep 17 00:00:00 2001 From: Daniel Bartholomew Date: Tue, 3 Nov 2020 10:56:50 -0500 Subject: [PATCH 04/15] bump the VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index a1f0ad08a61..b451aa8a789 100644 --- a/VERSION +++ b/VERSION @@ -1,3 +1,3 @@ MYSQL_VERSION_MAJOR=10 MYSQL_VERSION_MINOR=2 -MYSQL_VERSION_PATCH=35 +MYSQL_VERSION_PATCH=36 From 4548e74bcca1c97def4fbe44a28940d465f6555b Mon Sep 17 00:00:00 2001 From: Daniel Bartholomew Date: Tue, 3 Nov 2020 10:58:05 -0500 Subject: [PATCH 05/15] bump the VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 7f3afc3090f..1eee99cfc9f 100644 --- a/VERSION +++ b/VERSION @@ -1,4 +1,4 @@ MYSQL_VERSION_MAJOR=10 MYSQL_VERSION_MINOR=3 -MYSQL_VERSION_PATCH=26 +MYSQL_VERSION_PATCH=27 SERVER_MATURITY=stable From c048053c8af5083d35f764c5707c0b4ddb549846 Mon Sep 17 00:00:00 2001 From: Alice Sherepa Date: Thu, 29 Oct 2020 15:20:48 +0100 Subject: [PATCH 06/15] MDEV-23103 rpl.rpl_gtid_delete_domain failed in buildbot --- mysql-test/suite/rpl/r/rpl_gtid_delete_domain.result | 2 +- mysql-test/suite/rpl/t/rpl_gtid_delete_domain.test | 12 +++--------- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/mysql-test/suite/rpl/r/rpl_gtid_delete_domain.result b/mysql-test/suite/rpl/r/rpl_gtid_delete_domain.result index 74648501fbe..9c36973427a 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_delete_domain.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_delete_domain.result @@ -22,7 +22,7 @@ START SLAVE IO_THREAD; include/wait_for_slave_io_error.inc [errno=1236] connection master; FLUSH BINARY LOGS; -PURGE BINARY LOGS TO 'master-bin.000002';; +include/wait_for_purge.inc "master-bin.000002" FLUSH BINARY LOGS DELETE_DOMAIN_ID=(11); SELECT @@global.gtid_binlog_pos, @@global.gtid_binlog_state; @@global.gtid_binlog_pos @@global.gtid_binlog_state diff --git a/mysql-test/suite/rpl/t/rpl_gtid_delete_domain.test b/mysql-test/suite/rpl/t/rpl_gtid_delete_domain.test index 0262998798a..5537b6fbf86 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_delete_domain.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_delete_domain.test @@ -53,17 +53,11 @@ START SLAVE IO_THREAD; # adjust the master binlog state FLUSH BINARY LOGS; --let $purge_to_binlog= query_get_value(SHOW MASTER STATUS, File, 1) ---eval PURGE BINARY LOGS TO '$purge_to_binlog'; +--let $purge_binlogs_to=$purge_to_binlog +--source include/wait_for_purge.inc + # with final removal of the extra domain -###adding to debug info to catch the failure (1076): ---error 0,1076 --eval FLUSH BINARY LOGS DELETE_DOMAIN_ID=($extra_domain_id) - -if ($mysql_errno == 1076) { - --echo ### Failure "Could not delete gtid domain" - --source include/show_rpl_debug_info.inc - } - SELECT @@global.gtid_binlog_pos, @@global.gtid_binlog_state; --connection slave From d01a034ac604a5f960b5f4d16e24e8951b74419f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Mon, 9 Nov 2020 15:50:37 +0200 Subject: [PATCH 07/15] MDEV-7620: Remove the data structures The instrumentation that was added in commit 90635c6fb5e51aa878b81b1285c758afc361c7dc (MDEV-7620) was effectively reverted in MariaDB Server 10.2.2, in commit 2e814d4702d71a04388386a9f591d14a35980bfe (which stopped reporting the statistics) and commit fec844aca88e1c6b9c36bb0b811e92d9d023ffb9 (which stopped updating the statistics). Let us remove the orphan data members to reduce the memory footprint. --- storage/innobase/include/trx0trx.h | 14 -------------- storage/innobase/trx/trx0trx.cc | 4 ---- 2 files changed, 18 deletions(-) diff --git a/storage/innobase/include/trx0trx.h b/storage/innobase/include/trx0trx.h index 4161d4d8563..048a050a28d 100644 --- a/storage/innobase/include/trx0trx.h +++ b/storage/innobase/include/trx0trx.h @@ -1113,20 +1113,6 @@ private: during bulk create index */ FlushObserver* flush_observer; public: - /* Lock wait statistics */ - ulint n_rec_lock_waits; - /*!< Number of record lock waits, - might not be exactly correct. */ - ulint n_table_lock_waits; - /*!< Number of table lock waits, - might not be exactly correct. */ - ulint total_rec_lock_wait_time; - /*!< Total rec lock wait time up - to this moment. */ - ulint total_table_lock_wait_time; - /*!< Total table lock wait time - up to this moment. */ - #ifdef WITH_WSREP os_event_t wsrep_event; /* event waited for in srv_conc_slot */ #endif /* WITH_WSREP */ diff --git a/storage/innobase/trx/trx0trx.cc b/storage/innobase/trx/trx0trx.cc index 13b4efb973b..245758cecd5 100644 --- a/storage/innobase/trx/trx0trx.cc +++ b/storage/innobase/trx/trx0trx.cc @@ -464,10 +464,6 @@ inline void trx_t::free() MEM_NOACCESS(&mod_tables, sizeof mod_tables); MEM_NOACCESS(&detailed_error, sizeof detailed_error); MEM_NOACCESS(&flush_observer, sizeof flush_observer); - MEM_NOACCESS(&n_rec_lock_waits, sizeof n_rec_lock_waits); - MEM_NOACCESS(&n_table_lock_waits, sizeof n_table_lock_waits); - MEM_NOACCESS(&total_rec_lock_wait_time, sizeof total_rec_lock_wait_time); - MEM_NOACCESS(&total_table_lock_wait_time, sizeof total_table_lock_wait_time); #ifdef WITH_WSREP MEM_NOACCESS(&wsrep_event, sizeof wsrep_event); #endif /* WITH_WSREP */ From 5171ab808ce7d42c51188d695608c849272a90dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Tue, 10 Nov 2020 07:56:04 +0200 Subject: [PATCH 08/15] MDEV-24171 index_online_log is instrumented as rw-lock, not mutex The row_log_t::mutex is a mutex, yet it was instrumented as rw-lock in PERFORMANCE_SCHEMA. --- storage/innobase/handler/ha_innodb.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc index 0617005a213..04683a6843b 100644 --- a/storage/innobase/handler/ha_innodb.cc +++ b/storage/innobase/handler/ha_innodb.cc @@ -614,6 +614,7 @@ static PSI_mutex_info all_innodb_mutexes[] = { PSI_KEY(ibuf_bitmap_mutex), PSI_KEY(ibuf_mutex), PSI_KEY(ibuf_pessimistic_insert_mutex), + PSI_KEY(index_online_log), PSI_KEY(log_sys_mutex), PSI_KEY(log_sys_write_mutex), PSI_KEY(mutex_list_mutex), @@ -671,7 +672,6 @@ static PSI_rwlock_info all_innodb_rwlocks[] = { PSI_RWLOCK_KEY(trx_i_s_cache_lock), PSI_RWLOCK_KEY(trx_purge_latch), PSI_RWLOCK_KEY(index_tree_rw_lock), - PSI_RWLOCK_KEY(index_online_log), PSI_RWLOCK_KEY(hash_table_locks) }; # endif /* UNIV_PFS_RWLOCK */ From cd927dd34555a34e733a01bf5af52470f57ce906 Mon Sep 17 00:00:00 2001 From: Anel Husakovic Date: Mon, 9 Nov 2020 11:58:49 +0100 Subject: [PATCH 09/15] MDEV-23769: MTR can abort before it prints the test result summary - Patch is solving generating report on warning To repeat the error run single worker: ``` ./mtr --mysqld=--lock-wait-timeout=-xx 1st 1st --force --parallel 1 ``` or `N` workers with `N+1` tests with failures and `force` ``` ./mtr --mysqld=--lock-wait-timeout=-xx 1st 1st grant5 --force --parallel 2 ``` - Patch is doing cosmetic fix of `current_test` log file which holds the old log value of test `CURRENT TEST:..` in `mark_log()` in case of `unknown option` and as such the logic which is using it's content doesn't output valid log content and doesn't generate valid `$test->{'comment'}` message.asdf - Closing the socket/handler after the removing the handler from IO for consistency Reviewed by: serg@mariadb.com --- mysql-test/mysql-test-run.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 900ef736a45..8093e7ecb6f 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -802,6 +802,7 @@ sub run_test_server ($$$) { # Client disconnected mtr_verbose("Child closed socket"); $s->remove($sock); + $sock->close; if (--$childs == 0){ return ("Completed", $test_failure, $completed, $extra_warnings); } @@ -971,6 +972,7 @@ sub run_test_server ($$$) { # Test failure due to warnings, force is off return ("Warnings in log", 1, $completed, $extra_warnings); } + next; } elsif ($line =~ /^SPENT/) { add_total_times($line); @@ -4184,6 +4186,7 @@ sub run_testcase ($$) { if (start_servers($tinfo)) { report_failure_and_restart($tinfo); + unlink $path_current_testlog; return 1; } } From 3bf726f5ffc568b15e9788eddcfe87d81a5f6ed5 Mon Sep 17 00:00:00 2001 From: Anel Husakovic Date: Thu, 5 Nov 2020 16:12:22 +0100 Subject: [PATCH 10/15] MDEV-24130: Cannot launch mariadbd via mysqld_safe - Patch 95bb3cb886cb64be3ee5ace660b used `my_which` function in `10.2` - Based on patch `355ee6877bec` from 10.3+ `command -v` is used instead of `my_which` so we are changing in this patch also - `ldconfig` is usually found in `/sbin` so make sure it is added in `$PATH` variable --- scripts/mysqld_safe.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/mysqld_safe.sh b/scripts/mysqld_safe.sh index 98398e5421f..8e8575f4c24 100644 --- a/scripts/mysqld_safe.sh +++ b/scripts/mysqld_safe.sh @@ -440,7 +440,8 @@ mysqld_ld_preload_text() { set_malloc_lib() { malloc_lib="$1" if expr "$malloc_lib" : "\(tcmalloc\|jemalloc\)" > /dev/null ; then - if ! my_which ldconfig > /dev/null 2>&1 + export PATH=$PATH:/sbin + if ! command -v ldconfig > /dev/null 2>&1 then log_error "ldconfig command not found, required for ldconfig -p" exit 1 From bd528b0c93409b81157314d9699af519fd9d52ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Tue, 10 Nov 2020 09:47:29 +0200 Subject: [PATCH 11/15] MDEV-24182 ibuf_merge_or_delete_for_page() contains dead code The function ibuf_merge_or_delete_for_page() was always being invoked with update_ibuf_bitmap=true ever since commit cd623508dff53c210154392da6c0f65b7b6bcf4c fixed up something after MDEV-9566. Furthermore, the parameter page_size is never being passed as a null pointer, and therefore it should better be a reference to a constant object. --- storage/innobase/buf/buf0buf.cc | 6 +- storage/innobase/ibuf/ibuf0ibuf.cc | 129 ++++++++++----------------- storage/innobase/include/ibuf0ibuf.h | 8 +- storage/innobase/log/log0recv.cc | 3 +- 4 files changed, 53 insertions(+), 93 deletions(-) diff --git a/storage/innobase/buf/buf0buf.cc b/storage/innobase/buf/buf0buf.cc index e2b68011077..a54d98adee0 100644 --- a/storage/innobase/buf/buf0buf.cc +++ b/storage/innobase/buf/buf0buf.cc @@ -4601,7 +4601,7 @@ evict_from_pool: if (!access_time && !recv_no_ibuf_operations) { ibuf_merge_or_delete_for_page( - block, page_id, &page_size, TRUE); + block, page_id, page_size); } buf_pool_mutex_enter(buf_pool); @@ -5678,7 +5678,7 @@ loop: /* Delete possible entries for the page from the insert buffer: such can exist if the page belonged to an index which was dropped */ if (!recv_recovery_is_on()) { - ibuf_merge_or_delete_for_page(NULL, page_id, &page_size, TRUE); + ibuf_merge_or_delete_for_page(NULL, page_id, page_size); } frame = block->frame; @@ -6133,7 +6133,7 @@ database_corrupted: ibuf_merge_or_delete_for_page( (buf_block_t*) bpage, bpage->id, - &bpage->size, TRUE); + bpage->size); } fil_space_release_for_io(space); diff --git a/storage/innobase/ibuf/ibuf0ibuf.cc b/storage/innobase/ibuf/ibuf0ibuf.cc index 7068dab77a4..ee6fd235d5e 100644 --- a/storage/innobase/ibuf/ibuf0ibuf.cc +++ b/storage/innobase/ibuf/ibuf0ibuf.cc @@ -4384,16 +4384,12 @@ exist entries for such a page if the page belonged to an index which subsequently was dropped. @param[in,out] block if page has been read from disk, pointer to the page x-latched, else NULL -@param[in] page_id page id of the index page -@param[in] update_ibuf_bitmap normally this is set to TRUE, but -if we have deleted or are deleting the tablespace, then we naturally do not -want to update a non-existent bitmap page */ +@param[in] page_id page id of the index page */ void ibuf_merge_or_delete_for_page( buf_block_t* block, const page_id_t page_id, - const page_size_t* page_size, - ibool update_ibuf_bitmap) + const page_size_t& page_size) { btr_pcur_t pcur; #ifdef UNIV_IBUF_DEBUG @@ -4417,81 +4413,50 @@ ibuf_merge_or_delete_for_page( return; } - /* We cannot refer to page_size in the following, because it is passed - as NULL (it is unknown) when buf_read_ibuf_merge_pages() is merging - (discarding) changes for a dropped tablespace. When block != NULL or - update_ibuf_bitmap is specified, then page_size must be known. - That is why we will repeat the check below, with page_size in - place of univ_page_size. Passing univ_page_size assumes that the - uncompressed page size always is a power-of-2 multiple of the - compressed page size. */ - - if (ibuf_fixed_addr_page(page_id, univ_page_size) - || fsp_descr_page(page_id, univ_page_size)) { + if (ibuf_fixed_addr_page(page_id, page_size) + || fsp_descr_page(page_id, page_size)) { return; } - fil_space_t* space; + fil_space_t* space = fil_space_acquire_silent(page_id.space()); - if (update_ibuf_bitmap) { + if (UNIV_UNLIKELY(!space)) { + block = NULL; + } else { + page_t* bitmap_page = NULL; + ulint bitmap_bits = 0; - ut_ad(page_size != NULL); + ibuf_mtr_start(&mtr); - if (ibuf_fixed_addr_page(page_id, *page_size) - || fsp_descr_page(page_id, *page_size)) { + bitmap_page = ibuf_bitmap_get_map_page( + page_id, page_size, &mtr); + + if (bitmap_page && + fil_page_get_type(bitmap_page) != FIL_PAGE_TYPE_ALLOCATED) { + bitmap_bits = ibuf_bitmap_page_get_bits( + bitmap_page, page_id, page_size, + IBUF_BITMAP_BUFFERED, &mtr); + } + + ibuf_mtr_commit(&mtr); + + if (!bitmap_bits) { + /* No changes are buffered for this page. */ + + fil_space_release(space); + if (UNIV_UNLIKELY(srv_shutdown_state) + && !srv_fast_shutdown + && (!block + || btr_page_get_index_id(block->frame) + != DICT_IBUF_ID_MIN + IBUF_SPACE_ID)) { + /* Prevent an infinite loop on slow + shutdown, in case the bitmap bits are + wrongly clear even though buffered + changes exist. */ + ibuf_delete_recs(page_id); + } return; } - - space = fil_space_acquire_silent(page_id.space()); - - if (UNIV_UNLIKELY(!space)) { - /* Do not try to read the bitmap page from the - non-existent tablespace, delete the ibuf records */ - block = NULL; - update_ibuf_bitmap = FALSE; - } else { - page_t* bitmap_page = NULL; - ulint bitmap_bits = 0; - - ibuf_mtr_start(&mtr); - - bitmap_page = ibuf_bitmap_get_map_page( - page_id, *page_size, &mtr); - - if (bitmap_page && - fil_page_get_type(bitmap_page) != FIL_PAGE_TYPE_ALLOCATED) { - bitmap_bits = ibuf_bitmap_page_get_bits( - bitmap_page, page_id, *page_size, - IBUF_BITMAP_BUFFERED, &mtr); - } - - ibuf_mtr_commit(&mtr); - - if (!bitmap_bits) { - /* No changes are buffered for this page. */ - - fil_space_release(space); - if (UNIV_UNLIKELY(srv_shutdown_state) - && !srv_fast_shutdown - && (!block - || btr_page_get_index_id(block->frame) - != DICT_IBUF_ID_MIN + IBUF_SPACE_ID)) { - /* Prevent an infinite loop on slow - shutdown, in case the bitmap bits are - wrongly clear even though buffered - changes exist. */ - ibuf_delete_recs(page_id); - } - return; - } - } - } else if (block != NULL - && (ibuf_fixed_addr_page(page_id, *page_size) - || fsp_descr_page(page_id, *page_size))) { - - return; - } else { - space = NULL; } mem_heap_t* heap = mem_heap_create(512); @@ -4541,7 +4506,7 @@ loop: if (block != NULL) { ibool success; - mtr.set_named_space(page_id.space()); + mtr.set_named_space(space); success = buf_page_get_known_nowait( RW_X_LATCH, block, @@ -4556,8 +4521,8 @@ loop: the block is io-fixed. Other threads must not try to latch an io-fixed block. */ buf_block_dbg_add_level(block, SYNC_IBUF_TREE_NODE); - } else if (update_ibuf_bitmap) { - mtr.set_named_space(page_id.space()); + } else if (space) { + mtr.set_named_space(space); } if (!btr_pcur_is_on_user_rec(&pcur)) { @@ -4658,7 +4623,7 @@ loop: ibuf_btr_pcur_commit_specify_mtr(&pcur, &mtr); ibuf_mtr_start(&mtr); - mtr.set_named_space(page_id.space()); + mtr.set_named_space(space); success = buf_page_get_known_nowait( RW_X_LATCH, block, @@ -4714,26 +4679,26 @@ loop: } reset_bit: - if (update_ibuf_bitmap) { + if (space) { page_t* bitmap_page; - bitmap_page = ibuf_bitmap_get_map_page(page_id, *page_size, + bitmap_page = ibuf_bitmap_get_map_page(page_id, page_size, &mtr); ibuf_bitmap_page_set_bits( - bitmap_page, page_id, *page_size, + bitmap_page, page_id, page_size, IBUF_BITMAP_BUFFERED, FALSE, &mtr); if (block != NULL) { ulint old_bits = ibuf_bitmap_page_get_bits( - bitmap_page, page_id, *page_size, + bitmap_page, page_id, page_size, IBUF_BITMAP_FREE, &mtr); ulint new_bits = ibuf_index_page_calc_free(block); if (old_bits != new_bits) { ibuf_bitmap_page_set_bits( - bitmap_page, page_id, *page_size, + bitmap_page, page_id, page_size, IBUF_BITMAP_FREE, new_bits, &mtr); } } diff --git a/storage/innobase/include/ibuf0ibuf.h b/storage/innobase/include/ibuf0ibuf.h index a69b63ee16b..1a5214085de 100644 --- a/storage/innobase/include/ibuf0ibuf.h +++ b/storage/innobase/include/ibuf0ibuf.h @@ -342,16 +342,12 @@ exist entries for such a page if the page belonged to an index which subsequently was dropped. @param[in,out] block if page has been read from disk, pointer to the page x-latched, else NULL -@param[in] page_id page id of the index page -@param[in] update_ibuf_bitmap normally this is set to TRUE, but -if we have deleted or are deleting the tablespace, then we naturally do not -want to update a non-existent bitmap page */ +@param[in] page_id page id of the index page */ void ibuf_merge_or_delete_for_page( buf_block_t* block, const page_id_t page_id, - const page_size_t* page_size, - ibool update_ibuf_bitmap); + const page_size_t& page_size); /*********************************************************************//** Deletes all entries in the insert buffer for a given space id. This is used diff --git a/storage/innobase/log/log0recv.cc b/storage/innobase/log/log0recv.cc index 446e0afe576..4c3886caeaf 100644 --- a/storage/innobase/log/log0recv.cc +++ b/storage/innobase/log/log0recv.cc @@ -320,8 +320,7 @@ public: &mtr, NULL)) { mutex_exit(&recv_sys->mutex); ibuf_merge_or_delete_for_page( - block, i->first, - &block->page.size, true); + block, i->first, block->page.size); mtr.commit(); mtr.start(); mutex_enter(&recv_sys->mutex); From 7b7e5922afa38241e0ed54aad266c54225d3f861 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Tue, 10 Nov 2020 13:49:01 +0200 Subject: [PATCH 12/15] MDEV-24156 trx_undo_left() fails to prevent overflow trx_undo_left(): Return 0 in case of an overflow, instead of returning a negative number interpreted as a large positive number. Also, add debug assertions to check that the pointer is within the page area. This should allow us to catch bugs like MDEV-24096 easier in the future. --- storage/innobase/trx/trx0rec.cc | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/storage/innobase/trx/trx0rec.cc b/storage/innobase/trx/trx0rec.cc index 4aecc8ae610..e3e1c33b305 100644 --- a/storage/innobase/trx/trx0rec.cc +++ b/storage/innobase/trx/trx0rec.cc @@ -128,20 +128,18 @@ trx_undo_parse_add_undo_rec( return(ptr + len); } -/**********************************************************************//** -Calculates the free space left for extending an undo log record. +/** Calculate the free space left for extending an undo log record. +@param page undo log page +@param ptr current end of the undo page @return bytes left */ -UNIV_INLINE -ulint -trx_undo_left( -/*==========*/ - const page_t* page, /*!< in: undo log page */ - const byte* ptr) /*!< in: pointer to page */ +static ulint trx_undo_left(const page_t *page, const byte *ptr) { - /* The '- 10' is a safety margin, in case we have some small - calculation error below */ - - return(UNIV_PAGE_SIZE - (ptr - page) - 10 - FIL_PAGE_DATA_END); + ut_ad(ptr >= &page[TRX_UNDO_PAGE_HDR + TRX_UNDO_PAGE_HDR_SIZE]); + /* The 10 is supposed to be an extra safety margin (and needed for + compatibility with older versions) */ + lint left= srv_page_size - (ptr - page) - (10 + FIL_PAGE_DATA_END); + ut_ad(left >= 0); + return left < 0 ? 0 : static_cast(left); } /**********************************************************************//** From d6ee28582a177679c79272c6db6a6f204d8fd49f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Wed, 11 Nov 2020 08:16:06 +0200 Subject: [PATCH 13/15] Cleanup: Remove dict_space_is_empty(), dict_space_get_id() As noted in commit 0b66d3f70d365bbb936aae4ca67892c17d68d241, MariaDB does not support CREATE TABLESPACE for InnoDB. Hence, some code that was added in commit fec844aca88e1c6b9c36bb0b811e92d9d023ffb9 and originally in mysql/mysql-server@c71dd213bd434c0579e454ab8880e6d3756b0fb0 is unused in MariaDB and should be removed. --- storage/innobase/dict/dict0dict.cc | 138 --------------------------- storage/innobase/include/dict0dict.h | 24 +---- 2 files changed, 1 insertion(+), 161 deletions(-) diff --git a/storage/innobase/dict/dict0dict.cc b/storage/innobase/dict/dict0dict.cc index e3ce13b5b27..2124fc05faa 100644 --- a/storage/innobase/dict/dict0dict.cc +++ b/storage/innobase/dict/dict0dict.cc @@ -6707,144 +6707,6 @@ dict_sys_get_size() return size; } -/** Look for any dictionary objects that are found in the given tablespace. -@param[in] space_id Tablespace ID to search for. -@return true if tablespace is empty. */ -bool -dict_space_is_empty( - ulint space_id) -{ - btr_pcur_t pcur; - const rec_t* rec; - mtr_t mtr; - bool found = false; - - rw_lock_x_lock(&dict_operation_lock); - mutex_enter(&dict_sys->mutex); - mtr_start(&mtr); - - for (rec = dict_startscan_system(&pcur, &mtr, SYS_TABLES); - rec != NULL; - rec = dict_getnext_system(&pcur, &mtr)) { - const byte* field; - ulint len; - ulint space_id_for_table; - - field = rec_get_nth_field_old( - rec, DICT_FLD__SYS_TABLES__SPACE, &len); - ut_ad(len == 4); - space_id_for_table = mach_read_from_4(field); - - if (space_id_for_table == space_id) { - found = true; - } - } - - mtr_commit(&mtr); - mutex_exit(&dict_sys->mutex); - rw_lock_x_unlock(&dict_operation_lock); - - return(!found); -} - -/** Find the space_id for the given name in sys_tablespaces. -@param[in] name Tablespace name to search for. -@return the tablespace ID. */ -ulint -dict_space_get_id( - const char* name) -{ - btr_pcur_t pcur; - const rec_t* rec; - mtr_t mtr; - ulint name_len = strlen(name); - ulint id = ULINT_UNDEFINED; - - rw_lock_x_lock(&dict_operation_lock); - mutex_enter(&dict_sys->mutex); - mtr_start(&mtr); - - for (rec = dict_startscan_system(&pcur, &mtr, SYS_TABLESPACES); - rec != NULL; - rec = dict_getnext_system(&pcur, &mtr)) { - const byte* field; - ulint len; - - field = rec_get_nth_field_old( - rec, DICT_FLD__SYS_TABLESPACES__NAME, &len); - ut_ad(len > 0); - ut_ad(len < OS_FILE_MAX_PATH); - - if (len == name_len && ut_memcmp(name, field, len) == 0) { - - field = rec_get_nth_field_old( - rec, DICT_FLD__SYS_TABLESPACES__SPACE, &len); - ut_ad(len == 4); - id = mach_read_from_4(field); - - /* This is normally called by dict_getnext_system() - at the end of the index. */ - btr_pcur_close(&pcur); - break; - } - } - - mtr_commit(&mtr); - mutex_exit(&dict_sys->mutex); - rw_lock_x_unlock(&dict_operation_lock); - - return(id); -} - -/** Determine the extent size (in pages) for the given table -@param[in] table the table whose extent size is being - calculated. -@return extent size in pages (256, 128 or 64) */ -ulint -dict_table_extent_size( - const dict_table_t* table) -{ - const ulint mb_1 = 1024 * 1024; - const ulint mb_2 = 2 * mb_1; - const ulint mb_4 = 4 * mb_1; - - page_size_t page_size = dict_table_page_size(table); - ulint pages_in_extent = FSP_EXTENT_SIZE; - - if (page_size.is_compressed()) { - - ulint disk_page_size = page_size.physical(); - - switch (disk_page_size) { - case 1024: - pages_in_extent = mb_1/1024; - break; - case 2048: - pages_in_extent = mb_1/2048; - break; - case 4096: - pages_in_extent = mb_1/4096; - break; - case 8192: - pages_in_extent = mb_1/8192; - break; - case 16384: - pages_in_extent = mb_1/16384; - break; - case 32768: - pages_in_extent = mb_2/32768; - break; - case 65536: - pages_in_extent = mb_4/65536; - break; - default: - ut_ad(0); - } - } - - return(pages_in_extent); -} - size_t dict_table_t::get_overflow_field_local_len() const { diff --git a/storage/innobase/include/dict0dict.h b/storage/innobase/include/dict0dict.h index 7351b5fb682..6cfb92a94d3 100644 --- a/storage/innobase/include/dict0dict.h +++ b/storage/innobase/include/dict0dict.h @@ -2,7 +2,7 @@ Copyright (c) 1996, 2018, Oracle and/or its affiliates. All Rights Reserved. Copyright (c) 2012, Facebook Inc. -Copyright (c) 2013, 2019, MariaDB Corporation. +Copyright (c) 2013, 2020, MariaDB Corporation. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software @@ -989,14 +989,6 @@ dict_tf_get_page_size( ulint flags) MY_ATTRIBUTE((const)); -/** Determine the extent size (in pages) for the given table -@param[in] table the table whose extent size is being - calculated. -@return extent size in pages (256, 128 or 64) */ -ulint -dict_table_extent_size( - const dict_table_t* table); - /** Get the table page size. @param[in] table table @return compressed page size, or 0 if not compressed */ @@ -1905,20 +1897,6 @@ UNIV_INTERN ulint dict_sys_get_size(); -/** Look for any dictionary objects that are found in the given tablespace. -@param[in] space_id Tablespace ID to search for. -@return true if tablespace is empty. */ -bool -dict_space_is_empty( - ulint space_id); - -/** Find the space_id for the given name in sys_tablespaces. -@param[in] name Tablespace name to search for. -@return the tablespace ID. */ -ulint -dict_space_get_id( - const char* name); - /** Free the virtual column template @param[in,out] vc_templ virtual column template */ UNIV_INLINE From 15550ed3a4d81423210a1729f72852d115da8190 Mon Sep 17 00:00:00 2001 From: Daniel Bartholomew Date: Wed, 11 Nov 2020 10:17:22 -0500 Subject: [PATCH 14/15] bump the VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index b451aa8a789..fa4ec3694cd 100644 --- a/VERSION +++ b/VERSION @@ -1,3 +1,3 @@ MYSQL_VERSION_MAJOR=10 MYSQL_VERSION_MINOR=2 -MYSQL_VERSION_PATCH=36 +MYSQL_VERSION_PATCH=37 From bafbfb5530e29a83aef7e6e55d5604e08b637681 Mon Sep 17 00:00:00 2001 From: Daniel Bartholomew Date: Wed, 11 Nov 2020 10:18:33 -0500 Subject: [PATCH 15/15] bump the VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 1eee99cfc9f..4a7dd018a2c 100644 --- a/VERSION +++ b/VERSION @@ -1,4 +1,4 @@ MYSQL_VERSION_MAJOR=10 MYSQL_VERSION_MINOR=3 -MYSQL_VERSION_PATCH=27 +MYSQL_VERSION_PATCH=28 SERVER_MATURITY=stable