summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-24962 addendum: mariabackup does not understand --log-bin-index and ↵10.6-MDEV-24962Julius Goryavsky2021-05-051-3/+13
| | | | --log-basename options
* MDEV-24962: Galera SST innobackupex-move ignores Environment settingsJulius Goryavsky2021-05-057-792/+1177
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After switching to the new mariabackup interface (instead of the outdated innobackupex interface, which is supported for compatibility), we need to explicitly pass a path to the datadir directory as a parameter, since in the new interface the value of this option is not automatically set in such a way that it always matches the SST/IST logic. This commit adds passing this option as an explicit parameter to mariabackup. This commit also removed unnecessary options that are not used and not supported by mariabackup. Also, numerous flaws in the common wsrep_sst_common script have been fixed: 1) There are many bash-specific constructs in the script that may not be supported by other interpreters, which can lead to the most unexpected errors during SST, because failures in the interpretation of bash-specific constructs lead to incorrect parsing of arguments; 2) There is parse_cnf() function which is often called by other scripts for the "mysqld" or "--mysqld" group, but it does not take into account the default group suffix, which leads to reading values only from the default group, which then leads to errors due to reading the default values instead of the values for a specific group; 3) Some options such as --user, --innodb-data-home-dir or --datadir are not removed from the --mysqld-args list, although they are processed inside scripts (and passing of these options funther may cause problems for mariabackup); 4) If an argument that the script understands is present in the --mysqld-args list twice, then this causes SST to fail, instead of reading the most recent value; 5) The "--host" parameter is technically still supported among the arguments of the SST scripts, but in reality scripts do not work with it as expected, especially if it has an IPv6 address; 6) If the port number is absent in the --address parameter value, but the port number is explicitly passed through the --port argument, then the scripts for mariabackup and xtrabackup-v2 fail; 7) If a new address interface is used (with the --address parameter), then automatic default port substitution is not performed, although it is supported for the legacy --host/--port interface. 8) If there are spaces in the parameter values after --mysqld_args, then their further transfer does not occur correctly, which causes mariabackup to fail during SST - the space splits the argument in such a way that it breaks the parsing of the following parameters; 9) If most of the parameters that are names or paths to the files or directories contain spaces, then SST scripts fail in an unpredictable way due to incorrect variable substitutions; 10) If the --log-bin option is passed among the arguments of myqlds (--mysqld-args) without a parameter, and the --binlog option is not specified, then the script cannot substitute the default name for binlog and cannot construct binlog name using the --log-basename argument (which is against server specifications); 11) Tail slashes are not removed from the directory names, which, upon further substitution, leads to the appearance of a double slash in the file paths; 12) The explicit --binlog parameter (which is now always transmitted from the server side) and the "hidden" --log-bin parameter in the list of arguments after --mysqld-args are perceived as two different parameters in different parts of the scripts, and if they are do not match for some reason, this will lead to failures during SST; Also, all new changes from the 10.6 branch have been migrated here, including the latest pull requests for authentication (only the part that concerns SST scripts). It also fixes dozens of other bugs in all SST scripts.
* MDEV-25491 fixup: Optimize fil_space_t::check_pending_operations()Marko Mäkelä2021-05-041-2/+2
|
* MDEV-25502: rpl.rpl_perfschema_applier_status_by_worker failed in bb with: ↵Sujatha2021-05-042-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Test assertion failed Problem: ======= Test assertion fails on slave. Assertion text: 'Last_Seen_Transaction should show .' Assertion condition: '"0-1-1" = ""' Assertion condition, interpolated: '"0-1-1" = ""' Assertion result: '0' Analysis: ======== Test case creates a table on master and it waits for it to be replicated to slave and applied by slave applier. On completion 'Last_Seen_Transaction' value from 'performance_schema.replication_applier_status_by_worker' table is compared with '@@gtid_slave_pos' to ensure its correctness. The test should ensure that user table and 'gtid_slave_pos' table are of same engine type 'InnoDB' to get consistent test results. This guarantees that 'gtid_slave_pos' table is updated as part of transaction commit. In the of such an engine consistency, user table gets created in default MyISAM storage engine and 'mysql.gtid_slave_pos' table gets created in Aria storage engine. When the test code reaches above assert there might be a delay in an update to 'gtid_slave_pos' table, which leads to test assertion failure. Fix: === Use InnoDB engine for both user table and 'mysql.gtid_slave_pos' table.
* Cleanup: Remove unnecessary InnoDB log writesMarko Mäkelä2021-05-043-46/+17
|
* MDEV-25506: Kill during DDL leaves orphan .ibd fileMarko Mäkelä2021-05-0413-158/+141
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before we create an InnoDB data file, we must have persistently started a DDL transaction and written a record in SYS_INDEXES as well as a FILE_CREATE record for creating the file. In that way, if InnoDB is killed before the DDL transaction is committed, the rollback will be able to delete the file in dict_drop_index_tree(). dict_build_table_def_step(): Do not create the tablespace. At this point, we have not written any log, not even for inserting the SYS_TABLES record. dict_create_sys_indexes_tuple(): Relax an assertion to tolerate a missing tablespace before the first index has been created in dict_create_index_step(). dict_build_index_def_step(): Relax the dict_table_open_on_name() parameter, because no tablespace may be available yet. tab_create_graph_create(), row_create_table_for_mysql(), tab_node_t: Remove key_id, mode. ind_create_graph_create(), row_create_index_for_mysql(), ind_node_t: Add key_id, mode. dict_create_index_space(): New function, to create the tablespace during clustered index creation. dict_create_index_step(): After the SYS_INDEXES record has been written, invoke dict_create_index_space() to create the tablespace if needed. fil_ibd_create(): Before creating the file, persistently write a FILE_CREATE record. This will also ensure that an incomplete DDL transaction will be recovered. After creating the file, invoke fsp_header_init().
* MDEV-18518 Multi-table CREATE and DROP transactions for InnoDBMarko Mäkelä2021-05-0427-1029/+359
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | InnoDB used to support at most one CREATE TABLE or DROP TABLE per transaction. This caused complications for DDL operations on partitioned tables (where each partition is treated as a separate table by InnoDB) and FULLTEXT INDEX (where each index is maintained in a number of internal InnoDB tables). dict_drop_index_tree(): Extend the MDEV-24589 logic and treat the purge or rollback of SYS_INDEXES records of clustered indexes specially: by dropping the tablespace if it exists. This is the only form of recovery that we will need. trx_undo_ddl_type: Document the DDL undo log record types better. trx_t::dict_operation: Change the type to bool. trx_t::ddl: Remove. trx_t::table_id, trx_undo_t::table_id: Remove. dict_build_table_def_step(): Remove trx_t::table_id logging. dict_table_close_and_drop(), row_merge_drop_table(): Remove. row_merge_lock_table(): Merged to the only callers, which can call lock_table_for_trx() directly. fts_aux_table_t, fts_aux_id, fts_space_set_t: Remove. fts_drop_orphaned_tables(): Remove. row_merge_rename_index_to_drop(): Remove. Thanks to MDEV-24589, we can simply delete the to-be-dropped indexes from SYS_INDEXES, while still being able to roll back the operation. ha_innobase_inplace_ctx: Make a few data members const. Preallocate trx. prepare_inplace_alter_table_dict(): Simplify the logic. Let the normal rollback take care of some cleanup. row_undo_ins_remove_clust_rec(): Simplify the parsing of SYS_COLUMNS. trx_rollback_active(): Remove the special DROP TABLE logic. trx_undo_mem_create_at_db_start(), trx_undo_reuse_cached(): Always write TRX_UNDO_TABLE_ID as 0.
* Merge 10.5 into 10.6Marko Mäkelä2021-05-0427-203/+345
|\
| * Merge 10.4 into 10.5Marko Mäkelä2021-05-0323-186/+294
| |\
| | * Update wsrep-libbb-10.4-wsrepJan Lindström2021-04-301-0/+0
| | |
| | * MDEV-22265 Connect string character limit too small for full 64 character ↵Kentoku SHIBA2021-04-295-0/+67
| | | | | | | | | | | | | | | | | | InnoDB table-name limit when using ad-hoc Spider server definitions. Fix length for getting default table name.
| | * MDEV-25553 : Avoid unnecessary rollbacks with SRbb-10.4-MDEV-25553Daniele Sciascia2021-04-2812-56/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes statement rollback for streaming replication. Previously, a statement rollback was turned into full transaction rollback in the case where the transaction had already replicated a fragment. This was introduced in the initial implementation of streaming replication due to the fact that we do not have a mechanism to perform a statement rollback on the applying side. This policy is however overly pessimistic, causing full rollbacks even in cases where a local statement rollback, would not require a statement rollback on the applying side. This happens to be case when the statement itself has not replicated any fragments. So the patch changes the condition that determines if a statement rollback should be turned into a full rollback accordingly. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * MDEV-22227 Assertion `state_ == s_exec' failed in ↵bb-10.4-MDEV-22227mkaruza2021-04-285-130/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | wsrep::client_state::start_transaction Removed redundant code for BF abort transaction in `thr_lock.cc`. TOI operations will ignore provided lock_wait_timeout and use `LONG_TIMEOUT` until operation is finished. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * MDEV-25630 Rollback of instant operation adds wrong column to secondary indexbb-10.4-MDEV-25630Thirunarayanan Balathandayuthapani2021-04-283-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: ======= InnoDB alter fails before applying instant operation. So rollback assigns wrong column to the secondary index field. It leads to the assert failure in the consecutive alter. Fix: === InnoDB shouldn't do rollback of instant operation when it fails before applying instant operation.
| | * MDEV-22265 Connect string character limit too small for full 64 character ↵Alexey Botchkov2021-04-273-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | InnoDB table-name limit when using ad-hoc Spider server definitions. The name of the table sent as an argument to the handler::init() has the database name in front of it. So we should use table_share->table_name.length.
| * | new column store 5.5.2-2Oleksandr Byelkin2021-05-021-0/+0
| | |
| * | Updated wsrep.variables after wsrep lib updateMonty2021-05-011-2/+5
| | |
| * | MDEV-25507 CHECK on encrypted Aria table complains about "Wrong LSN"Monty2021-04-304-15/+44
| | | | | | | | | | | | | | | | | | | | | | | | This happens during repair when a temporary table is opened with HA_OPEN_COPY, which resets 'share->born_transactional', which the encryption code did not like. Fixed by resetting just share->now_transactional.
| * | MDEV-22265 Connect string character limit too small for full 64 character ↵Kentoku SHIBA2021-04-306-1/+69
| | | | | | | | | | | | | | | | | | InnoDB table-name limit when using ad-hoc Spider server definitions. Fix length for getting default table name.
* | | MDEV-25509 Atomic DDL: Assertion `err != DB_DUPLICATE_KEY' failsbb-10.6-MDEV-25509Thirunarayanan Balathandayuthapani2021-04-304-2/+35
| | | | | | | | | | | | | | | | | | | | | | | | after previous error upon multi-RENAME - InnoDB fails to rename the foreign key constraint while rollbacking the rename operation. In that case, InnoDB should rename the FK constraint too.
* | | MDEV-25491 fixup: Race between DROP TABLE and purge of DROP INDEXMarko Mäkelä2021-04-301-7/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | xdes_get_descriptor_with_space_hdr(): Use the correct mode BUF_GET_POSSIBLY_FREED also when the tablespace is larger than innodb_page_size pages. This function could be called by fseg_free_step(). fsp_alloc_seg_inode(): For completeness (and for improved robustness in case of a corrupted tablespace), use BUF_GET_POSSIBLY_FREED. With this, the entire compilation unit fsp0fsp.cc will use that mode.
* | | MDEV-25506 fixup for WindowsVladislav Vaintroub2021-04-301-1/+1
| | | | | | | | | | | | make os_file_rename_func work on Windows the same as on Unix.
* | | MDEV-25524 fixup for WindowsMarko Mäkelä2021-04-291-1/+2
| | | | | | | | | | | | | | | | | | | | | In commit 54e2e70194b9374543fdfc81a47d583e34771fac we relaxed a debug assertion in the POSIX version of os_file_rename_func() only. Let us relax it also on Windows, so that the test innodb.truncate_crash will pass.
* | | MDEV-25524 heap-use-after-free in fil_space_t::rename()Marko Mäkelä2021-04-2910-253/+164
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit 91599701d07a9efb02a2f27d17a8f95bc2b9accf (MDEV-25312) some recovery code for TRUNCATE TABLE was broken causing a regression in a case where undo log for a RENAME TABLE operation had been durably written but the tablespace had not been renamed yet. row_rename_table_for_mysql(): Add a DEBUG_SYNC point for the test case, and simplify the logic and trim the error messages. fil_space_t::rename(): Simplify the operation. Merge the necessary part of fil_rename_tablespace_check(). If there is no change to the file name, do nothing. dict_table_t::rename_tablespace(): Refactored from dict_table_rename_in_cache(). row_undo_ins_parse_undo_rec(): On rolling back TRX_UNDO_RENAME_TABLE, invoke dict_table_t::rename_tablespace() even if the table name matches. os_file_rename_func(): Temporarily relax an assertion that would fail during the recovery in the test innodb.truncate_crash.
* | | Merge 10.5 into 10.6Marko Mäkelä2021-04-2924-232/+617
|\ \ \ | |/ /
| * | MDEV-25530 Error 1451 on slave: Cannot delete or update a parent row: a ↵Sergei Golubchik2021-04-293-14/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | foreign key constraint fails after dfb41fddf6 tables that failed to drop are excluded from the binlogged DROP TABLE statement. It means that the slave should not expect any errors when executing DROP TABLE, and the binlog should report that no error has happened, even if it was. Do not write error code into the binlogged DROP TABLE, and remove all code that was needed to compute it.
| * | MDEV-24382 Assertion in tdc_remove_tableVladislav Vaintroub2021-04-282-0/+33
| | | | | | | | | | | | | | | | | | The assert is no more reproducible in the lastest 10.5-10.6 The patch only adds testcase from MDEV-24382.
| * | MDEV-25093: Adaptive flushing fails to kick in even ifKrunal Bauskar2021-04-281-4/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | innodb_adaptive_flushing_lwm is hit. (possible regression) adaptive flushing should kick in if a. dirty_pct (dirty pages in buffer pool) > innodb_max_dirty_pages_pct_lwm OR b. innodb_adaptive_flushing_lwm limit is reached (default to 10%) both conditions are mutually exclusive and whichever is first to evaluate true should kick-start the adaptive flushing. After recent changes to simplify the flushing algorithm logic, (b) got ignored that introduced the said regression.
| * | Merge 10.4 into 10.5Marko Mäkelä2021-04-2719-512/+664
| |\ \ | | |/
| | * Merge 10.3 into 10.4Marko Mäkelä2021-04-2714-4/+257
| | |\
| | | * MDEV-24545 Sequence created by one connection remains invisible to anotherst-10.3Marko Mäkelä2021-04-273-1/+33
| | | | | | | | | | | | | | | | | | | | | | | | row_merge_is_index_usable(): Allow access to any SEQUENCE, even if it was created after the read view. SQL sequences are no-rollback tables with no history at all.
| | | * Merge 10.2 into 10.3Marko Mäkelä2021-04-272-2/+2
| | | |\
| | | | * MDEV-25513: raise systemd LimitNOFILE limits to match server defaultsDaniel Black2021-04-272-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Quoting MDEV reporter Daniel Lewart: Starting MariaDB with default configuration causes the following problems: "[Warning] Could not increase number of max_open_files to more than 16384 (request: 32186)" silently reduces table_open_cache_instances from 8 (default) to 4 Default Server System Variables: extra_max_connections = 1 max_connections = 151 table_open_cache = 2000 table_open_cache_instances = 8 thread_pool_size = 4 LimitNOFILE=16834 is in the following files: support-files/mariadb.service.in support-files/mariadb@.service.in Looking at sql/mysqld.cc lines 3837-3917: wanted_files= (extra_files + max_connections + extra_max_connections + tc_size * 2 * tc_instances); wanted_files+= threadpool_size; Plugging in the default values: wanted_files = (30 + 151 + 1 + 2000 * 2 * 8 + 4) = 32186 However, systemd configuration has LimitNOFILE = 16384, which is far smaller. I suggest increasing LimitNOFILE to 32768.
| | | | * MDEV-24898: Server crashes in st_select_lex::next_selectbb-10.2-tmp1Sergei Petrunia2021-04-252-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | (trivial backport to 10.2) Add a testcase
| | | | * MDEV-24925: Server crashes in Item_subselect::init_expr_cache_trackerSergei Petrunia2021-04-253-1/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (trivial backport to 10.2) The optimizer removes redundant GROUP BY operations. If GROUP BY element is a subselect, it is "eliminated". However one must not eliminate the item if it is used both in the select list and in the GROUP BY, like so: select (select ... ) as SUBQ from ... group by SUBQ Do not eliminate such items.
| | | * | MDEV-24758 heap-use-after-poison in innobase_add_instant_try/rec_copyMarko Mäkelä2021-04-267-19/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a backport of commit fd9ca2a742abe2e91b2b77e70915dec7bd3cd7e1 (MDEV-23295) and commit 9a156e1a23046ba3e37bdb1e4e1ad887d3f5829b (MDEV-23345) to 10.3. An instant ADD/DROP/reorder column could create a dummy table object with the wrong ROW_FORMAT when innodb_default_row_format was changed between CREATE TABLE and ALTER TABLE. prepare_inplace_alter_table_dict(): If we had promised that ALGORITHM=INPLACE is supported, we must preserve the ROW_FORMAT. The rest of the changes are related to adding Alter_inplace_info::inplace_supported to cache the return value of handler::check_if_supported_inplace_alter().
| | | * | MDEV-24773: slave_compressed_protocol doesn't work properly with semi-sync ↵Sujatha2021-04-264-0/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | replication Back port upstream fix commit 1800b015a1d487330f7b15f2020b887be348a66b Author: Venkatesh Duggirala <venkatesh.duggirala@oracle.com> Date: Fri Sep 8 20:29:22 2017 +0530 Bug#26027024 SLAVE_COMPRESSED_PROTOCOL DOESN'T WORK WITH SEMI-SYNC REPLICATION IN MYSQL-5.7 Analysis: In mysql-5.6, dump thread (the thread that is created on Master after Slave requested for a binlog dump) is also used to receive acknowledgements from the Slave and act on them accordingly. For performance reasons, a special thread called Ack Receiver thread is added in mysql-5.7 Semi synchronous replication plugin. This thread does not have special handling to receive acknowledgements if Slave has enabled compression in the protocol. Hence Master is unable to handle any slave if Slave_compressed_protocol is enabled on it. Fix: Enable compress flag on the communication channels if the Slave has Slave_compressed_protocol ON.
| | | * | MDEV-24898: Server crashes in st_select_lex::next_selectbb-10.3-mdev24925Sergei Petrunia2021-04-252-0/+24
| | | | | | | | | | | | | | | | | | | | Add a testcase
| | | * | MDEV-24925: Server crashes in Item_subselect::init_expr_cache_trackerSergei Petrunia2021-04-253-1/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The optimizer removes redundant GROUP BY operations. If GROUP BY element is a subselect, it is "eliminated". However one must not eliminate the item if it is used both in the select list and in the GROUP BY, like so: select (select ... ) as SUBQ from ... group by SUBQ Do not eliminate such items.
| | * | | Fix MTR test wsrep.variables_debugDaniele Sciascia2021-04-265-508/+407
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test was changing variable wsrep_provider dynamically, but wsrep_provider was recently made read-only. followup for ce3a2a688db556d8
| * | | | MDEV-15756: Remove some garbage outputMarko Mäkelä2021-04-261-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | os_aio_print(): Remove output that should have been removed in commit 5e62b6a5e06eb02cbde1e34e95e26f42d87fce02 (MDEV-16264).
* | | | | Update wsrep-libbb-10.6-MDEV-22131Jan Lindström2021-04-291-0/+0
| | | | |
* | | | | MDEV-22131 allow transition from unencrypted to TLS cluster communication ↵mkaruza2021-04-293-0/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | without cluster downtime Cluster communication should be possible even when: 1. Node 2 is TCP 2. Node 1/3 is dynamic with SSL enabled During test we shutdown Node 2 and enable SSL on it. It should connect back to cluster successfully.
* | | | | MDEV-25534 Assertion lock_table_has...LOCK_IXMarko Mäkelä2021-04-284-7/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ha_innobase::start_stmt(): Always set m_prebuilt->sql_stat_start. row_search_mvcc(): Cleanup: Simplify debug assertions.
* | | | | MDEV-25522: Purge of aborted ADD INDEX leaves orphan locks behindMarko Mäkelä2021-04-283-2/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lock_discard_for_index(): New function, to discard locks for an index whose index tree has been purged. By definition, such indexes must be ones for which the MDL upgrade failed in inplace ALTER TABLE and the ADD INDEX operation was never committed. Note: Because we do not support online ADD SPATIAL INDEX, we only have to traverse the lock_sys.rec_hash for B-trees and not the hash tables for R-trees. row_purge_remove_clust_if_poss_low(): Invoke lock_discard_for_index() if necessary before dropping a B-tree for a SYS_INDEXES record.
* | | | | dict_drop_index_tree(): More robust corruption handlingMarko Mäkelä2021-04-281-11/+23
| | | | |
* | | | | MDEV-25491: Race condition between DROP TABLE and purge of SYS_INDEXES recordMarko Mäkelä2021-04-287-220/+318
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | btr_free_if_exists(): Always use the BUF_GET_POSSIBLY_FREED mode when accessing pages, because due to MDEV-24589 the function fil_space_t::set_stopping(true) can be called at any time during the execution of this function. mtr_t::m_freeing_tree: New data member for debugging purposes. buf_page_get_low(): Assert that the BUF_GET mode is not being used anywhere during the execution of btr_free_if_exists(). In all code related to freeing or allocating pages, we will add some robustness, by making more use of BUF_GET_POSSIBLY_FREED and by reporting an error instead of crashing in some cases of corruption.
* | | | | MDEV-25491 preparation: Clean up tablespace destructionMarko Mäkelä2021-04-283-217/+110
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fil_check_pending_ops(), fil_check_pending_io(): Remove. These functions were actually duplicating each other ever since commit 118e258aaac5da75a2ac4556201aaea3688fac67 (MDEV-23855). fil_space_t::check_pending_operations(): Replaces fil_check_pending_operations() and incorporates the logic of fil_check_pending_ops(). Avoid unnecessary lookups for the tablespace. Just wait for the reference count to drop to zero. fil_space_t::io(): Remove an unnecessary condition. We can (and probably better should) refuse asynchronous reads of undo tablespaces that are being truncated. fil_truncate_prepare(): Remove. trx_purge_truncate_history(): Implement the necessary steps that used to be in fil_truncate_prepare().
* | | | | MDEV-22265 Connect string character limit too small for full 64 character ↵Kentoku SHIBA2021-04-286-1/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | InnoDB table-name limit when using ad-hoc Spider server definitions. Fix length for getting default table name.
* | | | | bump the VERSIONDaniel Bartholomew2021-04-261-1/+1
| | | | |