summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Fix test failure on galera_var_reject_queries.bb-10.1-janJan Lindström2018-03-212-2/+2
|
* Disable a failing testMarko Mäkelä2018-03-211-0/+1
|
* Merge 10.0 into 10.1Marko Mäkelä2018-03-206-0/+54
|\
| * Merge 5.5 into 10.0Marko Mäkelä2018-03-204-0/+22
| |\
| | * PR #666: MDEV-15030 Add ASAN instrumentationMarko Mäkelä2018-03-203-0/+12
| | |\ | | | | | | | | | | | | | | | | mem_heap_create_block(): Poison the payload area until mem_heap_alloc() unpoisons it.
| | | * honor alignment rules and xtradb tooEugene Kosov2018-03-203-1/+11
| | | |
| | | * MDEV-15030 Add ASAN instrumentationEugene Kosov2018-03-191-0/+2
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Learn both valgrind and asan to catch this bug: mem_heap_t* heap = mem_heap_create(1024); byte* p = reinterpret_cast<byte*>(heap) + sizeof(mem_heap_t); *p = 123; Overflows of the last allocation in a block will be catched too. mem_heap_create_block(): poison newly allocated memory
| | * MDEV-12190 YASSL isn't able to negotiate TLS version correctlyVladislav Vaintroub2018-03-141-0/+10
| | | | | | | | | | | | Backport from 10.2
| * | MDEV-6736: Valgrind warnings 'Invalid read' in ↵Varun Gupta2018-03-173-1/+35
| | | | | | | | | | | | | | | | | | | | | | | | subselect_engine::calc_const_tables with SQ in WHERE and HAVING, ORDER BY, materialization+semijoin During cleanup a pointer to the materialised table that was freed was not set to NULL
* | | MDEV-12396 IMPORT TABLESPACE: Do not retry partial readsMarko Mäkelä2018-03-206-30/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fil_iterate(), fil_tablespace_iterate(): Replace os_file_read() with os_file_read_no_error_handling(). os_file_read_func(), os_file_read_no_error_handling_func(): Do not retry partial reads. There used to be an infinite amount of retries. Because InnoDB extends both data and log files upfront, partial reads should be impossible during normal operation.
* | | MDEV-12396 IMPORT cleanup: ROW_FORMAT=COMPRESSEDMarko Mäkelä2018-03-202-124/+116
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Initialize block.page.zip only once. PageConverter::update(): Initialize m_page_zip_ptr as late as possible. (We should really remove it at some point.) PageConverter::operator(): Refer to block->page.zip instead of m_page_zip_ptr. AbstractCallback::get_frame(): Define static. Refer to block->page.zip.data directly. fil_iterate(): Refer to block->page.zip.data directly. fil_tablespace_iterate(): Initialize block.page.zip.data as soon as possible.
* | | MDEV-12396 IMPORT TABLESPACE: Simplify validationMarko Mäkelä2018-03-202-318/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fil_iterate(): Validate the pages directly. import_page_status_t, PageConverter::validate(): Remove. AbstractCallback::filename(): New accessor. AbstractCallback::is_interrupted(): Replaces periodic_check(). PageConverter::trigger_corruption(): Remove.
* | | MDEV-12396 IMPORT TABLESPACE cleanupMarko Mäkelä2018-03-206-1183/+1008
| | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce unnecessary inter-module calls for IMPORT TABLESPACE. Move some IMPORT-related code from fil0fil.cc to row0import.cc. PageCallback: Remove. Make AbstractCallback the base class. PageConverter: Define some member functions inline.
* | | MDEV-12255 innodb_prefix_index_cluster_optimization hits debug buildThirunarayanan Balathandayuthapani2018-03-204-233/+1155
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | assert on UTF-8 columns Problem: ======= (1) Multi-byte character cases are not considered during prefix index cluster optimization check. It leads to fetch of improper results during read operation. (2) Strict assert in row_sel_field_store_in_mysql_format_func and it asserts for prefix index record to mysql conversion. Solution: ======== (1) Consider the case of multi-byte character during prefix index cluster optimization check. (2) Relax the assert in row_sel_field_store_in_mysql_format_func to allow prefix index record to mysql format conversion. The patch is taken from https://github.com/laurynas-biveinis/percona-server/commit/1eee538087ffcf121c37f844b447ba5480faf081
* | | Fix test case MW-329.Jan Lindström2018-03-202-0/+3
| | |
* | | Refs: MW-245 - Adjust tests to account for the new behavior.Philip Stoev2018-03-205-7/+10
| | |
* | | Refs: MW-245 - changed logic so that in non primary node it is possible to ↵sjaakola2018-03-201-3/+4
| | | | | | | | | | | | do SET + SHOW + SELECT from information and pfs schema, when dirty reads are not enabled - however, non table selects are not allowed (e.g. SELECT 1)
* | | Refs MW-245 - logic was wrong in detecting if queries are allowed in non ↵sjaakola2018-03-201-1/+2
| | | | | | | | | | | | primary node. it allowed select with no table list to execute even if dirty reads was not specified
* | | refs MW-245: Galera MTR Tests: additional tests for wsrep_reject_queries, ↵Philip Stoev2018-03-202-0/+65
| | | | | | | | | | | | wsrep_dirty_reads
* | | refs MW-245 - allowing USE <database> with dirty reads configuration - fix ↵sjaakola2018-03-202-19/+18
| | | | | | | | | | | | for logic of setting wsrep ready status
* | | refs MW-245 - merged wsrep_dirty_reads and wsrep_reject_queries from PXCsjaakola2018-03-2014-18/+131
| | |
* | | MDEV-12737: tokudb_mariadb.mdev6657 fails in buildbot with different plan, ↵Varun Gupta2018-03-202-4/+6
| | | | | | | | | | | | | | | | | | and outside with valgrind warnings Fixing the test by adding replace column for the rows column in the explain.
* | | MDEV-10991: Server crashes in spider_udf_direct_sql_create_conn - tests in ↵Jacob Mathew2018-03-192-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | spider/oracle* suites crash the server The crash occurs due to code that is #ifdef'd out with HAVE_ORACLE_OCI that pertains to the use of Spider with an Oracle data tier. Enabling this code eliminates the crash. The reason that MariaDB needs to support Oracle storage at the data tier is to help customers migrate from Oracle. It is necessary to build Spider with the additional build flag -DHAVE_ORACLE_OCI, and install and start Oracle before running the Oracle test suite or any tests within it. Nevertheless, if Spider is built normally and Oracle has not been started, these tests should not cause the MariaDB server to crash. The bug fix replaces the crash with the following error: ERROR 12501 (HY000) at line 4: The connect info 'ORACLE' is invalid Author: Jacob Mathew. Reviewer: Kentoku Shiba.
* | | Merge branch '10.0-galera' into 10.1Vicențiu Ciorbaru2018-03-195-4/+35
|\ \ \
| * | | MDEV-8743: where O_CLOEXEC is available, use for innodb buf_dumpDaniel Black2018-03-153-2/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As this is the only moderately critical fopened for writing file, create an alternate path to use open and fdopen for non-glibc platforms that support O_CLOEXEC (BSDs). Tested on Linux (by modifing the GLIBC defination) to take this alternate path: $ cd /proc/23874 $ more fdinfo/71 pos: 0 flags: 02100001 mnt_id: 24 $ ls -la fd/71 l-wx------. 1 dan dan 64 Mar 14 13:30 fd/71 -> /dev/shm/var_auto_i7rl/mysqld.1/data/ib_buffer_pool.incomplete
| * | | Merge pull request #636 from ↵Jan Lindström2018-03-141-1/+1
| |\ \ \ | | | | | | | | | | | | | | | | | | | | grooverdan/10.0-galera-MDEV-8743-linux-aio-ib_logfile0 MDEV-8743: ib_logfile0 Use O_CLOEXEC so galera SST scripts don't get fd
| | * | | MDEV-8743: ib_logfile0 Use O_CLOEXEC so galera SST scripts don't get fdDaniel Black2018-03-021-1/+1
| |/ / /
| * | | Bump wsrep patch version to 25.23Teemu Ollakka2018-02-251-1/+1
| | | |
| * | | bump the VERSIONDaniel Bartholomew2018-02-061-1/+1
| | | |
* | | | MDEV-15005 ASAN: stack-buffer-overflow in my_strnncollsp_simpleAlexander Barkov2018-03-195-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cmp_item_sort_string::store_value() did not cache the string returned from item->val_str(), whose result can point to various private members such as Item_char_typecast::tmp_value. - cmp_item_sort_string::store_value() remembered the pointer returned from item->val_str() poiting to tmp_value into cmp_item_string::value_res. - Later, cmp_item_real::store_value() was called, which called Item_str_func::val_real(), which called Item_char_typecast::val_str(&tmp) using a local stack variable "String tmp". Item_char_typecast::tmp_value was overwritten and become a link to "tmp": tmp_value.Ptr freed its own buffer and set to point to the buffer owned by "tmp". - On return from Item_str_func::val_real(), "String tmp" was destructed, but "tmp_value" still pointed to the buffer owned by "tmp", So tmp_value.Ptr became invalid. - Then cmp_item_sort_string() passed cmp_item_string::value_res to sortcmp(). At this point, value_res still pointed to an invalid value of Item_char_typecast::tmp_value. Fix: changing cmp_item_sort_string::store_value() to force copying to cmp_item_string::value if item->val_str(&value) returned a different pointer (instead of &value).
* | | | MDEV-13549: Galera test failuresJan Lindström2018-03-195-2/+10
| | | | | | | | | | | | | | | | Fix test failure on galera_flush_local.
* | | | MDEV-13549: Galera test failuresJan Lindström2018-03-192-4/+3
| | | | | | | | | | | | | | | | Fix test failure on galera_concurrent_ctas
* | | | MDEV-14875: galera_new_cluster crashes mysqld when existing server contains ↵Jan Lindström2018-03-191-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | databases Fortify wsrep_hton so that wsrep calls are not done to NULL-pointers.
* | | | MDEV-15321:different results when using value of ↵Varun Gupta2018-03-163-6/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | optimizer_use_condition_selectivity=4 and =1 To disallow equality propagation for DATETIME with non-zero YYYYMMDD part we were setting null_value to true. This caused issues when we were calculating selectivity for a condition as this returned IMPOSSIBLE WHERE. The issue is resolved by not setting null_value to true for DATETIME with non-zero YYYYMMDD.
* | | | MDEV-14265 - RPMLint warning: shared-lib-calls-exitSergey Vojtovich2018-03-1628-83/+45
| | | | | | | | | | | | | | | | Eliminated last exit() call from libmysqld.
* | | | Conditionally define TRX_WSREP_ABORTMarko Mäkelä2018-03-164-10/+22
| | | |
* | | | Fix a deadlock in thd_report_wait_for()Marko Mäkelä2018-03-166-30/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unlike commit a54abf01753a69c2186d60c155212149be59a7a6 claimed, the caller of THD::awake() may actually hold the InnoDB lock_sys->mutex. That commit introduced a deadlock of threads in the replication slave when running the test rpl.rpl_parallel_optimistic_nobinlog. lock_trx_handle_wait(): Expect the callers to acquire and release lock_sys->mutex and trx->mutex. innobase_kill_query(): Restore the logic for conditionally acquiring and releasing the mutexes. THD::awake() can be called from inside InnoDB while holding one or both mutexes, via thd_report_wait_for() and via wsrep_innobase_kill_one_trx().
* | | | Follow-up to MDEV-11236/MDEV-14846 debug assertionMarko Mäkelä2018-03-152-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | ha_innobase::unlock_row(): Use a relaxed version of the trx_state_eq() debug assertion, because rr_unlock_row() may be invoked after an error has been already reported and the transaction has been rolled back.
* | | | lock_table_create(), lock_rec_create(): Clean up the WSREP codeMarko Mäkelä2018-03-152-66/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By definition, c_lock->trx->lock.wait_lock==c_lock cannot hold. That is, the owner transaction of a lock cannot be waiting for that particular lock. It must have been waiting for some other lock. Remove the dead code related to that. Also, test c_lock for NULLness only once.
* | | | innobase_kill_query(): Use lock_trx_handle_wait()Marko Mäkelä2018-03-152-128/+24
| | | | | | | | | | | | | | | | | | | | The caller of THD::awake() should never hold any InnoDB mutexes, so we can always acquire lock_sys->mutex and trx->mutex.
* | | | Merge pull request #663 from ↵Jan Lindström2018-03-153-15/+28
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | codership/MDEV-13549-fixes-for-galera_var_slave_threads MDEV-13549 Fix and re-enable test galera.galera_var_slave_threads
| * | | | MDEV-13549 Fix and re-enable test galera.galera_var_slave_threadsDaniele Sciascia2018-03-153-15/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two changes were made to the test: 1) Suppress warning "Refusing exit for the last slave thread." This warning was already suppressed, but on the wrong node. 2) The test occasionally fails because it expects that the number of applier threads changes immediately after changing the value of ```variable wsrep_slave_threads```. Which is not true. This patch turns snippets like this: ``` SET GLOBAL wsrep_slave_threads = x; SELECT COUNT(*) = x FROM INFORMATION_SCHEMA.PROCESSLIST WHERE USER = 'system user'; ``` Into proper wait_conditions: ``` SET GLOBAL wsrep_slave_threads = x; let $wait_condition = SELECT COUNT(*) = x FROM ...; --source include/wait_condition.inc ```
* | | | | Merge pull request #650 from codership/MDEV-14144Jan Lindström2018-03-153-10/+2
|\ \ \ \ \ | | | | | | | | | | | | MDEV-14144 Fix for MTR tests complaining "Query didn't return a result set"
| * \ \ \ \ Merge branch '10.1' into MDEV-14144Jan Lindström2018-03-1528-149/+347
| |\ \ \ \ \ | |/ / / / / |/| | | | |
* | | | | | Merge pull request #654 from ↵Jan Lindström2018-03-152-34/+0
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | codership/MDEV-13549-fixes-for-galera_var_max_ws_rows MDEV-13549 Fix for test galera.galera_var_max_ws_rows
| * \ \ \ \ \ Merge branch '10.1' into MDEV-13549-fixes-for-galera_var_max_ws_rowsJan Lindström2018-03-1528-115/+347
| |\ \ \ \ \ \ | |/ / / / / / |/| | | | | |
* | | | | | | Merge pull request #656 from codership/MDEV-13549-fixes-for-MW-366Jan Lindström2018-03-153-18/+11
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | MDEV-13549 Fix and re-enable MTR test galera.MW-366
| * | | | | | | MDEV-13549 Fix and re-enable MTR test galera.MW-366Daniele Sciascia2018-03-133-18/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Test galera.MW-366 is not deterministic and depends on timing assumptions. The test occasionally fails after checking the number of 'system user' processes in processlist after changing the value of variable global wsrep_slave_threads, like this: ``` SET GLOBAL wsrep_slave_threads = x; --sleep 0.5 SELECT COUNT(*) = x FROM INFORMATION_SCHEMA.PROCESSLIST WHERE USER = 'system user'; ``` The problem is that the number of slave threads is internally adjusted 'asynchronously', and it may take some time to spawn/kill new threads, especially in a heavily loaded system. This patch removes the '--sleep 0.5' statements from the test and replaces those with appropriate wait conditions, like this: ``` SET GLOBAL wsrep_slave_threads = x; let $wait_condition = SLECT COUNT(*) = x FROM ...; --source include/wait_condition.inc ```
* | | | | | | | Merge pull request #659 from ↵Jan Lindström2018-03-153-16/+53
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | codership/MDEV-13549-fixes-for-galera_bf_abort_for_update MDEV-13549 Fix and re-enable test galera.galera_bf_abort_for_update
| * | | | | | | | MDEV-13549 Re-enable test galera.galera_bf_abort_for_updateDaniele Sciascia2018-03-141-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Test passes reliably after applying missing commit from upstream.