summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-23659: Update Galera disabled.def filebb-10.2-MDEV-21770Julius Goryavsky2020-10-151-5/+0
| | | | | This fix removes from the list of disabled tests all tests that were fixed by the patch for MDEV-21770.
* MDEV-21770: `galera_3nodes.galera_ipv6_mariabackup` failsJulius Goryavsky2020-10-153-31/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes several flaws in the SST scripts that cause failures while running tests that use version 6 IP addresses for cluster nodes. First, if the netcat utility is used for streaming (but not socat), then in accordance with its command line syntax, we need to remove the square brackets around the IPv6 address. However, for socat, the address must contain square brackets, as before. Secondly, if an IPv6 address is used, then from the joiner side for a number of systems (such as Debian) we need to explicitly specify the "-6" option, otherwise a listening socket with an IPv6 address may not be created. This patch also contains code improvements in the wsrep_sst_common. Changed the code that pars the connection address - fixed the shortcomings that sometimes led to incorrect parsing of parameters when using shells other than the latest versions of bash. Also, this patch removes the duplicate code that is intended for parsing the connection address and which was located in the wsrep_sst_mariabackup file, since all the necessary actions have already been done in wsrep_sst_common and there they are done in such a way that any shell is supported, not just bash. The fix does not require separate tests, since all the necessary tests are already present in the galera_3nodes suite. On the contrary, after this fix, tests using IPv6 addresses can be removed from the disabled list (this will be done in a separate commit related to MDEV-23659).
* MDEV-23960 UBSAN ../storage/innobase/buf/buf0buddy.cc:350:6: runtime error: ↵Eugene Kosov2020-10-141-1/+1
| | | | | | index 4096 out of bounds for type 'byte [38]' Reviewed by: Marko Mäkelä
* MDEV-23955 main.multi_update_big times outMarko Mäkelä2020-10-144-73/+20
| | | | | | | Copying generated data from the sequence engine should be faster than copying from MyISAM to MyISAM. Reviewed by: Sergei Petrunia
* minor fixes of rpl_start_stop_slave and rpl_slave_grp_exec tests, expanding ↵Alice Sherepa2020-10-146-5/+21
| | | | rpl_gtid_delete_domain for easier later analysis
* MDEV-21584 Linux aio returned OS error 22Eugene Kosov2020-10-143-7/+28
| | | | | | | | | | | | | | | | Sometimes blockdev --getss returns 4096. In that case ROW_FORMAT=COMPRESSED tables might violate that 4096 bytes alignment. This patch disables O_DIRECT for COMPRESSED tables. OS_DATA_FILE_NO_O_DIRECT: new possible value for os_file_create() argument fil_node_open_file(): do not O_DIRECT ROW_FORMAT=COMPRESSED tables AIO::is_linux_native_aio_supported(): minimal alignment in a general case is 4096 and not 512.
* Add missing file.Jan Lindström2020-10-101-0/+9
|
* MDEV-23659 : Update Galera disabled.def fileJan Lindström2020-10-102-2/+0
| | | | | | Changes to be committed: modified: mysql-test/suite/galera/disabled.def modified: mysql-test/suite/wsrep/disabled.def
* MDEV-17585 : wsrep.variables failed in buildbot with deadlock on CREATE USERJan Lindström2020-10-104-32/+40
| | | | | Stabilize test by using correct galera library and restore original galera cluster at end.
* MDEV-19968 : Galera test failure on galera_load_dataJan Lindström2020-10-102-18/+35
| | | | Add necessary wait_conditions to stabilize test.
* MDEV-21329 InnoDB: Failing assertion: ↵Thirunarayanan Balathandayuthapani2020-10-081-0/+5
| | | | | | | | | | | | | | | | | lock->lock_word.load(std::memory_order_relaxed) == X_LOCK_DECR upon server shutdown Problem is that dropping of fts table and sync of fts table happens concurrently during fts optimize thread shutdown. fts_optimize_remove_table() is executed by a user thread that performs DDL, and that the fts_optimize_wq may be removed if fts_optimize_shutdown() has started executing. fts_optimize_remove_table() doesn't remove the table from the queue and it leads to above scenario. While removing the table from fts_optimize_wq, if the table can't be removed then wait till fts_optimize_thread shuts down. Reviewed-by: Marko Mäkelä
* Merge tag 'mariadb-10.2.34' into 10.2Sergei Golubchik2020-10-071-5/+46
|\
| * Merge branch '10.1' into 10.2mariadb-10.2.34Sergei Golubchik2020-10-052-6/+47
| |\
| | * bump VERSIONmariadb-10.1.47Sergei Golubchik2020-10-051-1/+1
| | |
| | * MDEV-23884 donor uses invalid SST methodsSergei Golubchik2020-10-051-5/+46
| | |
* | | bump the VERSIONDaniel Bartholomew2020-10-071-1/+1
| | |
* | | MDEV-23811: With large number of indexes optimizer chooses an inefficient planIgor Babaev2020-10-065-11/+201
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This bug could manifest itself for a query with WHERE condition containing top level OR formula such that each conjunct contained a single-range condition supported by the same index. One of these range conditions must be fully covered by another range condition that is used later in the OR formula. Additionally at least one of these condition should be ANDed with a sargable range condition supported by a different index. There were several attempts to fix related problems for OR conditions after the backport of range optimizer code from MySQL (commit 0e19f3e36f7842583feb6bead2c2600cd620bced). Unfortunately the first of these fixes contained typo remained unnoticed until recently. This typo bug led to rejection of valid range accesses. This patch fixed this typo bug. The fix revealed another two bugs: one in a constructor for SEL_ARG, the other in the function tree_or(). Both are fixed in this patch.
* | | MDEV-23897 SIGSEGV on commit with innodb_lock_schedule_algorithm=VATSMarko Mäkelä2020-10-062-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This regression for debug builds was introduced by MDEV-23101 (commit 224c950462a22e09f4e2e37d19218c9129bccba6). Due to MDEV-16664, the parameter innodb_lock_schedule_algorithm=VATS is not enabled by default. The purpose of the added assertions was to enforce the invariant that Galera replication cannot be enabled together with VATS due to MDEV-12837. However, upon closer inspection, it is obvious that the variable 'lock' may be assigned to the null pointer if no match is found in the previous->hash list. lock_grant_and_move_on_page(), lock_grant_and_move_on_rec(): Assert !lock->trx->is_wsrep() only after ensuring that lock is not a null pointer.
* | | MDEV-23787 mtr --rr fixesAleksey Midenkov2020-10-063-3/+14
| | | | | | | | | | | | | | | | | | 1. rr record -h randomizes number of processors. Disable THREAD_POOL_SIZE check. 2. check for kernel.perf_event_paranoid for user-friendly error message.
* | | MDEV-18163 Assertion `table_share->tmp_table != NO_TMP_TABLE || m_lock_type ↵Oleksandr Byelkin2020-10-063-0/+27
| | | | | | | | | | | | | | | | | | != 2' failed in handler::ha_rnd_next(); / Assertion `table_list->table' failed in find_field_in_table_ref / ERROR 1901 (on optimized builds) Add the same check for altering DEFAULT used as for CREATE TABLE.
* | | travis: 10.2 only - make fasterDaniel Black2020-10-061-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove from debian build: * tokudb * mroonga * spider * ograph * embedded server Add ccache to debian build. Backport 10.3 changes to autobake-deb that make travis faster. Merge instructions: Drop this commit on merge to 10.3
* | | MDEV-23894 UBSAN: several call to function show_binlog_vars(THD*, ↵Eugene Kosov2020-10-064-10/+11
| | | | | | | | | | | | st_mysql_show_var*, char*) through pointer to incorrect function type 'int (*)(THD *, st_mysql_show_var *, void *, system_status_var *, enum_var_type) errors
* | | MDEV-18593 : galera.galera_gcache_recover_full_gcache: Test failure: ↵Jan Lindström2020-10-062-3/+17
| | | | | | | | | | | | | | | | | | galera_gcache_recover_full_gcache.test: assert_grep.inc failed Grep only the fact that we need to fall back to SST.
* | | MDEV-23888: Potential server hang on replication with InnoDBMarko Mäkelä2020-10-061-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In MDEV-21452, SAFE_MUTEX flagged an ordering problem that involved trx_t::mutex, LOCK_global_system_variables, and LOCK_commit_ordered when running ./mtr --no-reorder\ binlog.binlog_checksum,mix binlog.binlog_commit_wait,mix Because LOCK_commit_ordered is acquired by replication code before innobase_commit_ordered() is invoked, and because LOCK_commit_ordered should be below LOCK_global_system_variables in the global latching order, it turns out that we must avoid acquiring LOCK_global_system_variables in any low-level code. It also turns out that lock_rec_lock() acquires lock_sys_t::mutex and then carries on to call lock_rec_enqueue_waiting(), which may invoke THDVAR() via thd_lock_wait_timeout(). This call is problematic if THDVAR() had never been invoked in that thread earlier. innobase_trx_init(): Let us invoke THDVAR() at the start of an InnoDB transaction so that future invocations of THDVAR() will avoid LOCK_global_system_variables acquisition on the same THD. Because the first call to intern_sys_var_ptr() will initialize all session variables by not passing the offset to sync_dynamic_session_variables(), this will indeed make any future THDVAR() invocation mutex-free. There are some THDVAR() calls in other code (related to indexed virtual columns, fulltext indexes, and DDL operations). No SAFE_MUTEX warning was known for those, but there does not appear to be any replication test coverage for indexed virtual columns or fulltext indexes. DDL should be covered, and perhaps DDL code paths were already invoking THDVAR() while not holding any InnoDB mutex. Side note: MySQL should avoid this type of deadlocks since mysql/mysql-server@4d275c89954685e2ed1b368812b3b5a29ddf9389. MariaDB never defined alloc_and_copy_thd_dynamic_variables(), because we prefer to avoid overhead during connection creation. An important part of the deadlock could be the current handling of SET GLOBAL binlog_checksum=NONE; and similar assignments. In binlog_checksum_update(), we would hold LOCK_global_system_variables while potentially acquiring LOCK_commit_ordered in MYSQL_BIN_LOG::open(). Even if that code was changed later to release LOCK_global_system_variables during the write to mysql_bin_log, it could be a good idea for performance to avoid invoking the expensive code path of THDVAR() while holding any InnoDB mutexes, such as lock_sys.mutex in lock_rec_enqueue_waiting(). Thanks to Andrei Elkin for debugging the SAFE_MUTEX issue, and to Sergei Golubchik for the suggestion to invoke THDVAR() early.
* | | UBSAN: UndefinedBehaviorSanitizer: undefined-behavior ↵Eugene Kosov2020-10-051-1/+4
| | | | | | | | | | | | ../sql/item_cmpfunc.cc:3650:14
* | | Remove unnecessary and incorrect add_suppression.Jan Lindström2020-10-052-3/+0
| | | | | | | | | | | | | | | | | | Changes to be committed: modified: mysql-test/suite/sys_vars/r/wsrep_cluster_address_basic.result modified: mysql-test/suite/sys_vars/t/wsrep_cluster_address_basic.test
* | | MDEV-16664: Add deprecation warning for innodb_lock_schedule_algorithm=VATSMarko Mäkelä2020-10-053-7/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The setting innodb_lock_schedule_algorithm=VATS that was introduced in MDEV-11039 (commit 021212b525e39d332cddd0b9f1656e2fa8044905) causes conflicting exclusive locks to be incorrectly granted to two transactions. Specifically, in lock_rec_insert_by_trx_age() the predicate !lock_rec_has_to_wait_in_queue(in_lock) would hold even though an active transaction is already holding an exclusive lock. This was observed between two DELETE of the same clustered index record. The HASH_DELETE invocation in lock_rec_enqueue_waiting() may be related. Due to lack of progress in diagnosing the problem, we will deprecate the option and issue a warning that using it may corrupt data. The unsafe option was enabled between commit 0c15d1a6ff0d18da946f050cfeac176387a76112 (MariaDB 10.2.3) and the parent of commit 1cc1d0429da14a041a6240c6fce17e0d31cad8e2 (MariaDB 10.2.17, 10.3.9).
* | | Cleanup: Remove unused SYNC_REC_LOCKMarko Mäkelä2020-10-052-11/+0
| | | | | | | | | | | | | | | SYNC_REC_LOCK was never used in the public history of InnoDB, starting with commit 132e667b0bbbe33137b6baeb59f3f22b7524f066.
* | | UBSAN UndefinedBehaviorSanitizer: undefined-behavior ../mysys/hash.c:798:9Eugene Kosov2020-10-031-3/+2
| | |
* | | MDEV-23879 server hangs with threadpool, compression, and client pipeliningVladislav Vaintroub2020-10-033-3/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Amend check for unread client data in threadpool. THD::NET will have unread data, in case client uses compression, and wraps multiple commands into a single compression packet MariaDB C/C sends COM_STMT_RESET+COM_STMT_EXECUTE, and wraps it into a single compressed packet, when compression is on, thus trying to use compression and prepared statements against a threadpool-enabled server will result into a hang, before this patch.
* | | Cleanup: Orphan que_thr_mutex declarationMarko Mäkelä2020-10-021-3/+0
| | | | | | | | | | | | | | | | | | The orphan declaration was added in MySQL 5.6.2 mysql/mysql-server@2915417e026ef9fdd8e36df17938409ccc157d86 and MariaDB commit 1d0f70c2f894b27e98773a282871d32802f67964.
* | | Cleanup: Remove fts_t::bg_threads_mutex, fts_t::bg_threadsMarko Mäkelä2020-10-027-25/+2
| | | | | | | | | | | | | | | | | | | | | | | | The unused fts_t::bg_threads was added in mysql/mysql-server@4b1049625c00dbfcd9d7a11ad12a84695ab747e3. Any usage of fts_t::bg_threads_mutex was removed in mysql/mysql-server@33c2404b397e1077daaf0ef0ff9edba445430f5f.
* | | MDEV-23856 fts_optimize_wq accessed after shutdown of FTS Optimize threadThirunarayanan Balathandayuthapani2020-09-301-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | In fts_optimize_remove_table(), InnoDB tries to access the fts_optimize_wq after shutting down the fts optimize thread. This issue caused by the commit a41d429765c7ddb528b9b438c68b25ff55d3bd55. Fix should check for fts optimize thread shutdown state before checking fts_optimize_wq.
* | | Cleanup: Remove unused fts_cache_t::optimize_lockMarko Mäkelä2020-09-307-12/+0
| | | | | | | | | | | | | | | This has been unused from the very beginning (mysql/mysql-server@d5e512ae7e37cd1f70c44a3f12205d70b13118ab).
* | | Cleanup: Remove constant parameters async=false, index_name=NULLMarko Mäkelä2020-09-294-41/+6
| | |
* | | MDEV-23839 innodb_fast_shutdown=0 hang on change buffer mergeMarko Mäkelä2020-09-291-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ibuf_merge_or_delete_for_page(): Do not attempt to invoke ibuf_delete_recs() on a page of the change buffer itself. The caller could already be holding ibuf->index->lock, and an attempt to acquire it in S mode would hang the release server or cause an assertion failure in rw_lock_s_lock_func() in a debug server. This problem was reproducible on 1 out of 2 runs of the following: ./mtr --no-reorder \ innodb.innodb-page_compression_default \ innodb.innodb-page_compression_snappy \ innodb.innodb-page_compression_zip \ innodb.innodb_wl6326_big innodb.xa_recovery
* | | Merge 10.1 into 10.2Marko Mäkelä2020-09-296-14/+42
|\ \ \
| * | | Cleanup: Remove unused rw_lock_t::writer_is_wait_exMarko Mäkelä2020-09-292-14/+2
| | | | | | | | | | | | | | | | | | | | This was missed in commit 2c252ba96b8f124f81371ec86843a45dc3977d54 (MySQL 5.5.42, MariaDB 5.5.42).
| * | | MDEV-22277 LeakSanitizer: detected memory leaks in ↵Thirunarayanan Balathandayuthapani2020-09-284-0/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | mem_heap_create_block_func after attempt to create foreign key - During online DDL, prepare phase error handler fails to remove the memory allocated for newly created foreign keys.
* | | | MDEV-23659 : Update Galera disabled.def fileJan Lindström2020-09-281-6/+5
| | | | | | | | | | | | | | | | Fix typo.
* | | | Merge branch '10.1' into 10.2Sujatha2020-09-2819-24/+103
|\ \ \ \ | |/ / /
| * | | MDEV-22330: mysqlbinlog stops with an error Don't know how to handle column ↵Sujatha2020-09-283-7/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | type: 255 meta: 4 (0004) Analysis: ======== "mysqlbinlog -v" option will reconstruct row events and display them as commented SQL statements. If this option is given twice, the output includes comments to indicate column data types and some metadata. `log_event_print_value` is the function reponsible for printing values and their types. This function doesn't handle GEOMETRY type. Hence the above error gets printed. Fix: === Add support for GEOMETRY datatype.
| * | | Reverted wrong patch for mysql_upgradebb-10.1-danielblack-mysqlupgrade-revertMonty2020-09-262-3/+3
| | | | | | | | | | | | | | | | | | | | The original code was correct. mysql_upgrade calls the mysql client to talk with MariaDB. It doesn't call itself!
| * | | Revert "[MDEV-7978] add show create user"Daniel Black2020-09-2416-701/+118
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Appoligies, had a dirty branch before pushing: This reverts commit 053653a23cac6f3f2e5288979438de27c9d0100a. This reverts commit 0ff897807fc2f4a32e1ba1ae148005930ea604b5. This reverts commit 85b085972b729f6c049050f851692c9a5b86f3d5. This reverts commit f3f45e46b614bddcef0a37f4352c5909ca565d1d. This reverts commit a470b3570a7ce2534c9021f3b84d7457a3ba08e1. This reverts commit f8b8d202bc83d3de46c89ef86333fe602e711265. This reverts commit 6b6f066fdd9f5f64813ded550e7dbda176ee3c82. This reverts commit a701e9e6c390c3cbac69872e95b1aec565341d30. This reverts commit c169838611e13c9f0559b2f49ba8c36aec11a78b.
| * | | MDEV-23697: /usr/bin/perl for debian scriptsDaniel Black2020-09-241-1/+1
| | | |
| * | | MDEV-23697: perl -w -> perlDaniel Black2020-09-2413-13/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Leave debian/additions/mysqlreport as #!/usr/bin/perl Acknowledge that `env perl` is a hack, a complete fix needs to consider which path perl is at and insert into these scripts. The usefulness of these scripts is questionable.
| * | | Merge branch '10.1' of https://github.com/MariaDB/server into 10.1Daniel Black2020-09-241-0/+5
| |\ \ \
| * | | | [MDEV-7978] Update test cases for sysvars_server_embedded.Vicențiu Ciorbaru2020-09-201-2/+2
| | | | |
| * | | | [MDEV-7978] Make show_create_user testcase not run on embedded buildVicențiu Ciorbaru2020-09-201-0/+2
| | | | |
| * | | | [MDEV-7978] Post review fixes and cleanups.Vicențiu Ciorbaru2020-09-204-12/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Maintain coding style in sql_yacc.yy in regards to optional clauses. * Remove unused variable from sql_acl.cc. * Update test case