- 10 May, 2018 2 commits
-
-
Sergei Golubchik authored
MDEV-15746 ASAN heap-use-after-free in Item_change_list::rollback_item_tree_changes on ALTER executed as PS don't try to convert a default value string from a user character set into a column character set, if this particular default value string did not came from the user at all (that is, if it's an ALTER TABLE and the default value string is the *old* default value of the unaltered column). This used to crash, because old defaults are allocated on the old table's memroot, which is freed mid-ALTER when the old table is closed. So thd->rollback_item_tree_changes() at the end of the ALTER was writing into the freed memory.
-
Sergei Golubchik authored
table.cc: virtual columns must be computed for INSERT, if they're part of the partitioning expression. this change broke gcol.gcol_partition_innodb. fix CHECK TABLE for partitioned tables and vcols. sql_partition.cc: mark prerequisite base columns in full_part_field_set ha_partition.cc initialize vcol_set accordingly
-
- 09 May, 2018 4 commits
-
-
Vladislav Vaintroub authored
This previously unreported warning comes from casting size_t to ulong in sql_hset.h in Hash_Set::at(). Change my_hash_element to accept size_t index parameter.
-
Jacob Mathew authored
The remote users need the SUPER privilege because by default Spider sends a 'SET SQL_LOG_OFF' statement to the data nodes. This is controlled by the spider_internal_sql_log_off configuration setting on the Spider node, which can only be set to 0 or 1, with a default value of 1. I have fixed the problem by changing this configuration setting so that if it is NOT SET, which is the most likely case, the Spider node DOES NOT SEND the 'SET SQL_LOG_OFF' statement to the data nodes. However if the spider_internal_sql_log_off setting IS EXPLICITLY SET to either 0 or 1, then the Spider node DOES SEND the 'SET SQL_LOG_OFF' statement, requiring a remote user with the SUPER privilege. The Spider documentation will be updated to reflect this change. Author: Jacob Mathew. Reviewer: Kentoku Shiba. Cherry-Picked: Commit 72f0efac on branch bb-10.3-MDEV-15697
-
Thirunarayanan Balathandayuthapani authored
Problem: ======= InnoDB master thread encounters the shutdown state as SRV_SHUTDOWN_FLUSH_PHASE when innodb_force_recovery >=2 and slow scheduling of master thread during shutdown. Fix: ==== There is no need for master thread itself if innodb_force_recovery >=2. Don't create the master thread if innodb_force_recovery >= 2
-
Marko Mäkelä authored
ibuf_restore_pos(): Do not issue any messages if the tablespace is being dropped or truncated. In MariaDB 10.2, TRUNCATE TABLE would not change the tablespace ID, and therefore the tablespace would be found, even though TRUNCATE is in progress. Furthermore, do not commit suicide if restoring the change buffer cursor fails. The worst that could happen is that a secondary index becomes corrupted due to incomplete change buffer merge.
-
- 08 May, 2018 1 commit
-
-
Thirunarayanan Balathandayuthapani authored
During rollback of temporary table logs, secondary index should delete mark the index entry instead of removing it completely.
-
- 07 May, 2018 2 commits
-
-
Igor Babaev authored
-
Marko Mäkelä authored
MDEV-14825 Assertion `col->ord_part' in row_build_index_entry_low upon ROLLBACK or DELETE with concurrent ALTER on partitioned table If creating a secondary index fails (typically, ADD UNIQUE INDEX fails due to duplicate key), it is possible that concurrently running UPDATE or DELETE will access the index stub and hit the debug assertion. It does not make any sense to keep updating an uncommitted index whose creation has failed. dict_index_t::is_corrupted(): Replaces dict_index_is_corrupted(). Also take online_status into account. Replace some calls to dict_index_is_clust() with calls to dict_index_t::is_primary().
-
- 04 May, 2018 1 commit
-
-
Marko Mäkelä authored
log_sys_init(), log_buffer_extend(): Add TRASH_ALLOC() instrumentation log_write_up_to(): Correctly calculate the byte offset.
-
- 02 May, 2018 1 commit
-
-
Jacob Mathew authored
When a comma separator is missing between COMMENT fields, Spider ignores the parameter values that are beyond the last expected parameter value. There are also some error messages that Spider does generate on COMMENT fields that are incorrectly formed. I have introduced additional infrastructure in Spider to fix these problems. Author: Jacob Mathew. Reviewer: Kentoku Shiba. Cherry-Picked: Commit c10da98b on branch bb-10.3-MDEV-15698
-
- 01 May, 2018 1 commit
-
-
Jacob Mathew authored
MDEV-15712: If remote server used by Spider table is unavailable, some operations hang for a long time When an attempt to connect to the remote server fails, Spider retries to connect to the remote server 1000 times or until the connection attempt succeeds. This is perceived as a hang if the remote server remains unavailable. I have introduced changes in Spider's table status handler to fix this problem. Author: Jacob Mathew. Reviewer: Kentoku Shiba. Cherry-Picked: Commit 6ee6933a on branch bb-10.3-MDEV-15712
-
- 28 Apr, 2018 1 commit
-
-
Marko Mäkelä authored
This reverts commit 72deed59 which was merged as commit 29d4ac2c. The change caused regressions, such as mysql-test-run failing to run at all with --valgrind, or aborting on Windows on the first test failure.
-
- 26 Apr, 2018 5 commits
-
-
Marko Mäkelä authored
In the merge of commit e7f4e61f the call fil_flush_file_spaces(FIL_TYPE_LOG) is necessary. Tablespaces will be flushed as part of the redo log checkpoint, but the redo log will not necessarily be flushed, depending on innodb_flush_method.
-
Marko Mäkelä authored
InnoDB takes a lot of time to perform null updates. The reason is that even though an empty update vector was created, InnoDB will go on to write undo log records and update the system columns DB_TRX_ID and DB_ROLL_PTR in the clustered index, and of course write redo log for all this. This could have been fixed properly in commit 54a492ec more than 10 years ago.
-
Marko Mäkelä authored
Remove the local variable srv_buf_pool_size_org, which was always 0. In MySQL 5.7, InnoDB was made a mandatory storage engine, which would force InnoDB to start up when executing mysqld --verbose --help which is what mysql-test-run.pl is doing as a first step. With a large innodb_buffer_pool_size, this would take a long time. So, MySQL 5.7 includes a hack that starts up InnoDB with a smaller buffer pool when the option --verbose is present.
-
Marko Mäkelä authored
MariaDB uses HAVE_LZO, not HAVE_LZO1X (which was never defined). Also, the variable srv_lzo_disabled was never defined or read (only declared and assigned to, in unreachable code).
-
Marko Mäkelä authored
The InnoDB system table column SYS_TABLES.MIX_LEN was repurposed in InnoDB Plugin for MySQL 5.1, in commit 91111174 (MySQL 5.1.46). Until MySQL 5.6, it only contained a flag DICT_TF2_TEMPORARY. MySQL 5.6 introduced a number of flags that were transient in nature. One of these was introduced in 5.6.5, originally called DICT_TF2_USE_TABLESPACE and later renamed to DICT_TF2_USE_FILE_PER_TABLE. MySQL 5.7.6 introduced logic that insists that the flag be set for any table that does not reside in a shared tablespace, breaking upgrade from MySQL 5.5. MariaDB does not support shared tablespaces other than the InnoDB system tablespace. Also, some dependencies on SYS_TABLES.MIX_LEN were removed in an earlier fix: MDEV-13084 MariaDB 10.2 crashes on corrupted SYS_TABLES.MIX_LEN field (commit e813fe86). dict_check_sys_tables(): Remove a bogus debug assertion, and add a comment that explains how DICT_TF2_USE_FILE_PER_TABLE is used. dict_table_is_file_per_table(): Remove a bogus debug assertion.
-
- 24 Apr, 2018 10 commits
-
-
Igor Babaev authored
It has been done to demonstrate that the fix of this bug is good for 10.3 as well. The previous test case is not good for this purpose because 10.2 and 10.3 use different rules for determining the types of recursive CTEs.
-
Marko Mäkelä authored
Pool::mem_free(): Poison the freed memory. Assert that it was fully initialized, because the reuse of trx_t objects will assume that the objects were previously initialized. Pool::~Pool(), Pool::get(): Unpoison the allocated memory, and mark it initialized. trx_free(): After invoking Pool::mem_free(), unpoison trx_t::mutex and trx_t::undo_mutex, because MutexMonitor will access these even for freed trx_t objects.
-
Marko Mäkelä authored
-
Eugene Kosov authored
-
Marko Mäkelä authored
Modern compilers (such as GCC 8) emit warnings that the 'register' keyword is deprecated and not valid C++17. Let us remove most use of the 'register' keyword. Code in 'extra/' is not touched.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
Apply the contributed patch from MySQL Bug #89126 create table panic on innobase_parse_hint_from_comment by Yan Huang.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
xb_assign_undo_space_start(): Correctly pass the length of the buffer, so that the file name will not be truncated.
-
- 23 Apr, 2018 9 commits
-
-
Marko Mäkelä authored
dict_load_table_low(): When flagging an error, assign *table = NULL. Failure to do so could cause a crash if an error was flagged when accessing INFORMATION_SCHEMA.INNODB_SYS_TABLES.
-
Jan Lindström authored
MDEV-15948 Fix error "Lost connection to MySQL server..." in test gal…
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
While the test case crashes a MariaDB 10.2 debug build only, let us apply the fix to the earliest applicable MariaDB series (10.0) to avoid any data corruption on a table-rebuilding ALTER TABLE using ALGORITHM=INPLACE. innobase_create_key_defs(): Use altered_table->s->primary_key when a new primary key is being created.
-
Daniele Sciascia authored
* Increased timeout counter in galera_wait_ready.inc * Replaced useless include/wait_until_ready.inc after start_mysqld.inc in galera_st_*.inc with wait_condition on cluster size.
-
Marko Mäkelä authored
-
Thirunarayanan Balathandayuthapani authored
MDEV-15374 Server hangs and aborts with long semaphore wait or assertion `len < ((ulint) srv_page_size)' fails in trx_undo_rec_copy upon ROLLBACK on temporary table Problem: ======= InnoDB cleans all temporary undo logs during commit. During rollback of secondary index entry, InnoDB tries to build the previous version of clustered index. It leads to access of freed undo page during previous transaction commit and it leads to undo log corruption. Solution: ========= During rollback, temporary undo logs should not try to build the previous version of the record.
-
Jan Lindström authored
MDEV-15929 Fix lock wait timeout on `SELECT @@GLOBAL.WSREP_ON`
-
- 21 Apr, 2018 3 commits
-
-
Marko Mäkelä authored
-
Sergei Golubchik authored
followup for a3c980b3 same change in Locked_tables_list::unlink_from_list(), otherwise thd->locked_tables_list will keep pointers to a free'd TABLE if prelocked under lock tables. This fixes a crash in main.create_or_replace on debug Win builds after bcb36ee2
-
Marko Mäkelä authored
-