- 05 Jun, 2019 1 commit
-
-
Sergei Petrunia authored
MDEV-19600: The optimizer should be able to produce rows=1 estimate for unique index with NULLable columns Modify best_access_path() to produce rows=1 estimate for null-rejecting lookups on unique NULL keys.
-
- 29 May, 2019 7 commits
-
-
Monty authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
row_search_mvcc(): Duplicate the logic of btr_pcur_move_to_next() so that an infinite loop can be avoided when advancing to the next page fails due to a corrupted page.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
Also, --skip-innodb-buffer-pool-load-at-startup to avoid a crash in buf_load() due to loading pages that we are corrupting intentionally.
-
- 28 May, 2019 15 commits
-
-
Marko Mäkelä authored
At higher levels of innodb_force_recovery, the InnoDB transaction subsystem will not be set up at all. At slightly lower levels, recovered transactions will not be rolled back, and DDL operations could hang due to locks being held at all. Let us consistently refuse all writes if the predicate high_level_read_only holds. We failed to refuse DROP TABLE and DROP DATABASE. (Refusing DROP TABLE is a partial backport from MDEV-19570 in the 10.5 branch.)
-
Thirunarayanan Balathandayuthapani authored
- Replace mysql_version check with omit_virtual_cols() in ha_innobase::check_if_supported_inplace_alter().
-
Marko Mäkelä authored
-
Thirunarayanan Balathandayuthapani authored
- If one of the encryption threads already started the initialization of the tablespace then don't remove the other uninitialized tablespace from the rotation list. - If there is a change in innodb_encrypt_tables then don't remove the processed tablespace from rotation list.
-
Marko Mäkelä authored
LOCK_global_system_variables: Declare with MYSQL_PLUGIN_IMPORT
-
Eugene Kosov authored
-
Eugene Kosov authored
-
Eugene Kosov authored
-
Eugene Kosov authored
-
Thirunarayanan Balathandayuthapani authored
- Don't apply redo log for the corrupted page when innodb_force_recovery > 0. - Allow the table to be dropped when index root page is corrupted when innodb_force_recovery > 0.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
The update callback functions for several settable global InnoDB variables are acquiring InnoDB latches while holding LOCK_global_system_variables. On the other hand, some InnoDB code is invoking THDVAR() while holding InnoDB latches. An example of this is thd_lock_wait_timeout() that is called by lock_rec_enqueue_waiting(). In some cases, the intern_sys_var_ptr() that is invoked by THDVAR() may acquire LOCK_global_system_variables, via sync_dynamic_session_variables(). In lock_rec_enqueue_waiting(), we really must be holding some InnoDB latch while invoking THDVAR(). This implies that LOCK_global_system_variables must conceptually reside below any InnoDB latch in the latching order. That in turns implies that the various update callback functions must release LOCK_global_system_variables before acquiring any InnoDB mutexes or rw-locks, and reacquire LOCK_global_system_variables later. The validate functions are being invoked while not holding LOCK_global_system_variables and thus they do not need any changes. The following statements are affected by this: SET GLOBAL innodb_adaptive_hash_index = …; SET GLOBAL innodb_cmp_per_index_enabled = 1; SET GLOBAL innodb_old_blocks_pct = …; SET GLOBAL innodb_fil_make_page_dirty_debug = …; -- debug builds only SET GLOBAL innodb_buffer_pool_evict = uncompressed; -- debug builds only SET GLOBAL innodb_purge_run_now = 1; -- debug builds only SET GLOBAL innodb_purge_stop_now = 1; -- debug builds only SET GLOBAL innodb_log_checkpoint_now = 1; -- debug builds only SET GLOBAL innodb_buf_flush_list_now = 1; -- debug builds only SET GLOBAL innodb_buffer_pool_dump_now = 1; SET GLOBAL innodb_buffer_pool_load_now = 1; SET GLOBAL innodb_buffer_pool_load_abort = 1; SET GLOBAL innodb_status_output = …; SET GLOBAL innodb_status_output_locks = …; SET GLOBAL innodb_encryption_threads = …; SET GLOBAL innodb_encryption_rotate_key_age = …; SET GLOBAL innodb_encryption_rotation_iops = …; SET GLOBAL innodb_encrypt_tables = …; SET GLOBAL innodb_disallow_writes = …; buf_LRU_old_ratio_update(): Correct the return type.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Igor Babaev authored
or server crashes in JOIN::fix_all_splittings_in_plan after EXPLAIN This patch resolves the problem of overflowing when performing calculations to estimate the cost of an evaluated query execution plan. The overflowing in a non-debug build could cause different kind of problems uncluding crashes of the server.
-
- 27 May, 2019 3 commits
-
-
Thirunarayanan Balathandayuthapani authored
- create_table_def() misconstructs the dict_table_t by ignoring the stored columns of the table if virtual column is present between stored columns.
-
Daniel Black authored
-
Monty authored
-
- 24 May, 2019 4 commits
-
-
Andrei Elkin authored
Simulation of a big-sized event in rpl.rpl_semi_sync_skip_repl did not clean up after itself so screw the last binlog event offset which could jump backwards. The test is refined to rotate a binlog file with simulation and use the next one for logics of the test incl master-slave synchonization.
-
Vlad Lesin authored
MDEV-14192: mariabackup.incremental_backup failed in buildbot with Failing assertion: byte_offset % OS_FILE_LOG_BLOCK_SIZE == 0 In some cases it's possible that InnoDB redo log file header is re-written so, that checkpoint lsn and checkpoint lsn offset are updated, but checkpoint number stays the same. The fix is to re-read redo log header if at least one of those three parametes is changed at backup start. Repeat the logic of log_group_checkpoint() on choosing InnoDB checkpoint info field on backup start. This does not influence backup correctness, but simplifies bugs analysis.
-
Marko Mäkelä authored
The INFORMATION_SCHEMA plugin INNODB_SYS_VIRTUAL, which was introduced in MariaDB 10.2.2 along with the dictionary table SYS_VIRTUAL, is similar to other, much older and already stable plugins that provide access to InnoDB dictionary tables.
-
Igor Babaev authored
This patch corrects the patch for the bug 10006. The latter incorrectly calculates the attribute TABLE_LIST::dep_tables for inner tables of outer joins that are to be converted into inner joins. As a result after the patch some valid join orders were not evaluated and the optimizer could choose an execution plan that was far from being optimal.
-
- 22 May, 2019 1 commit
-
-
Robert Bindar authored
Running trigger_null-8605 drop_bad_db_type tests in this order was failing due to unremoved temporary files created in trigger_null-8605
-
- 21 May, 2019 6 commits
-
-
Sergei Golubchik authored
-
Varun Gupta authored
The code in best_access_path function, when it does not find a key suitable for ref access and join_cache_level is set to a value so that hash_join is possible we build a hash key. Later in the function we compare the cost of ref access with table scan (or index scan or quick selects). No need to do this when we have got the hash key.
-
Ian Gilfillan authored
-
Marko Mäkelä authored
-
Daniele Sciascia authored
Bootstrapping a new cluster from a backup created from a MariaDB version prior to 10.3.5 may result in error "SST position can't be set in past" when attempting to join additional nodes. The problem stems from the fact that when reading the wsrep position from InnoDB, the position is looked up in two places: the TRX_SYS page, where versions prior to 10.3.5 used to store WSREP's position; and rollback segments, this is where newer versions store the position. When starting a new cluster, the starting seqno is 0 and a new cluster UUID is generated. This is persisted in rollback segments, but the old UUID and seqno are not cleared from TRX_SYS page. Subsequently, when reading back the position, trx_rseg_read_wsrep_checkpoint() is going to return the maximum seqno found in both TRX_SYS page and rollback segments. So in the case of a newly bootstrapped cluster, it's always going to return the old cluster information. The fix consists of changing trx_rseg_read_wsrep_checkpoint() so that only rollback segments are looked up. On startup, position is read from the TRX_SYS page, and if present, it is copied to rollback segments (unless a newer position is already present in the rollback segments). Finally the position stored in TRX_SYS page is cleared.
-
Monty authored
-
- 20 May, 2019 3 commits
-
-
Sergei Golubchik authored
post-merge changes Closes #954
-
Eugene Kosov authored
This patch is for MEM_ROOT only. In debug mode add 8 byte of poisoned memory before every allocated chunk. On the right of every chunk there will be either 1-7 trailing poisoned bytes, or next chunk's redzone, or poisoned non allocated memory or redzone of a malloc()ed buffer.
-
Marko Mäkelä authored
-