summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-21806 : galera.galera_partition MTR failed: failed to recover from ↵bb-10.4-MDEV-20451-galeraJan Lindström2021-09-273-0/+12
| | | | | | DONOR state Add wait_condition to wait until all nodes are in cluster
* Add wait_condition before problematic selectJan Lindström2021-09-273-2/+25
|
* Merge 10.3 into 10.4Marko Mäkelä2021-09-249-146/+132
|\
| * Merge 10.2 into 10.3Marko Mäkelä2021-09-248-146/+124
| |\
| | * Revert MDEV-25114Marko Mäkelä2021-09-2418-766/+230
| | | | | | | | | | | | | | | | | | Revert 88a4be75a5f3b8d59ac8f6347ff2c197813c05dc and 9d97f92febc89941784d17d59c60275e21140ce0, which had been prematurely pushed by accident.
| | * Update libmariadbMarko Mäkelä2021-09-241-0/+0
| | |
| | * MDEV-26360: Using hostnames breaks certificate validationbb-10.2-MDEV-26360-galeraJulius Goryavsky2021-09-244-59/+136
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed flaws with overly strict or, conversely, overly soft verification of certificates in some scenarios: 1. Removed the check that the 'commonname' (CN) in the certificate matches the 'localhost' value on the side of the joiner node, which was performed earlier, even if the address was received by the script only as an argument (out of the exchange via the Galera protocol) - since for the joining node this argument always contains its own local address, not the address of the remote host, so it is always treated as 'localhost', which is not necessarily true (outside of mtr testing); 2. Removed checking the domain name or IP-address of the peer node in the encrypt=2 mode; 3. Fixed checking of compliance of certificates when rsync SST is used; 4. Added the ability to specify CA not only as a file, but also as a path to the directory where the certificates are stored. To do this, the user just needs to specify the path to this directory as the value ssl-ca or tca parameter, ending with the '/' character.
| | * MDEV-26612 Two different ways to start MariaDB service can cause data corruptionbb-10.2-MDEV-26612Alexey Bychko2021-09-241-8/+7
| | | | | | | | | | | | | | | | | | | | | RedHat systems have both files for lsb and init functions. Old code was written as if/else, so second file (RedHat-specific) was not processed. So, systemd redirect didn't work, because its logic is described in RedHat-specific functions file
| | * Revert "MDEV-24978 : SIGABRT in __libc_message"bb-10.2-MDEV-24978-fJan Lindström2021-09-243-94/+21
| | | | | | | | | | | | This reverts commit 30dea4599e44e3008fb9bc5fe79ab5747841f21f.
| | * MDEV-25114 Crash: WSREP: invalid state ROLLED_BACK (FATAL)sjaakola2021-09-2418-151/+725
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is the plan D variant for fixing potetial mutex locking order exercised by BF aborting and KILL command execution. In this approach, KILL command is replicated as TOI operation. This guarantees total isolation for the KILL command execution in the first node: there is no concurrent replication applying and no concurrent DDL executing. Therefore there is no risk of BF aborting to happen in parallel with KILL command execution either. Potential mutex deadlocks between the different mutex access paths with KILL command execution and BF aborting cannot therefore happen. TOI replication is used, in this approach, purely as means to provide isolated KILL command execution in the first node. KILL command should not (and must not) be applied in secondary nodes. In this patch, we make this sure by skipping KILL execution in secondary nodes, in applying phase, where we bail out if applier thread is trying to execute KILL command. This is effective, but skipping the applying of KILL command could happen much earlier as well. This patch also fixes mutex locking order and unprotected THD member accesses on bf aborting case. We try to hold THD::LOCK_thd_data during bf aborting. Only case where it is not possible is at wsrep_abort_transaction before call wsrep_innobase_kill_one_trx where we take InnoDB mutexes first and then THD::LOCK_thd_data. This will also fix possible race condition during close_connection and while wsrep is disconnecting connections. Added wsrep_bf_kill_debug test case Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * Revert "MDEV-23328 Server hang due to Galera lock conflict resolution" andJan Lindström2021-09-242-112/+74
| | | | | | | | | | | | | | | | | | | | | Revert "MDEV-24873 galera.galera_as_slave_ctas MTR failed:..." This reverts commit 29bbcac0ee841faaa68eeb09c86ff825eabbe6b6 and later commit 5ecaf52d42a1e464c71515f35be97855072bcafe.
| * | Fixup "Windows, mysqltest : cleanup, remove dead code USE_CYGWIN"Vladislav Vaintroub2021-09-241-0/+8
| | | | | | | | | | | | | | | last commit 8221708e389728aef799046eef3c49b1eec2e400 removed too much, mtr is failing
* | | Merge branch '10.3' into 10.4Vladislav Vaintroub2021-09-246-170/+193
|\ \ \ | |/ /
| * | Windows, mysqltest : cleanup, remove dead code USE_CYGWINVladislav Vaintroub2021-09-241-54/+0
| | |
| * | MDEV-11499 mysqltest, Windows : improve diagnostics if server fails to shutdownVladislav Vaintroub2021-09-246-117/+193
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Create minidump when server fails to shutdown. If process is being debugged, cause a debug break. Moves some code which is part of safe_kill into mysys, as both safe_kill, and mysqltest produce minidumps on different timeouts. Small cleanup in wait_until_dead() - replace inefficient loop with a single wait.
* | | Merge 10.3 into 10.4Marko Mäkelä2021-09-247-37/+34
|\ \ \ | |/ /
| * | MDEV-26672 innodb_undo_log_truncate may reset transaction ID sequenceMarko Mäkelä2021-09-248-37/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | trx_rseg_header_create(): Add a parameter for the value that is to be written to TRX_RSEG_MAX_TRX_ID. If we omit this write, then the updated test innodb.undo_truncate will fail for the 4k, 8k, 16k page sizes. This was broken ever since commit 947efe17ed8188ca4feef6deb0c2831a246b5c8f (MDEV-15158) removed the writes of transaction identifiers to the TRX_SYS page. srv_do_purge(): Truncate undo tablespaces also during slow shutdown (innodb_fast_shutdown=0). Thanks to Krunal Bauskar for noticing this problem.
* | | Update wsrep-lib submoduleJan Lindström2021-09-241-0/+0
| | |
* | | MDEV-26566 : galera.galera_var_cluster_address MTR failed: InnoDB: Assertion ↵Jan Lindström2021-09-235-11/+220
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | failure in file row0ins.cc line 3206 Actual problem was that we tried to calculate persistent statistics to wsrep_schema tables in this case wsrep_streaming_log. These tables should not have persistent statistics. Therefore, in table creation tables should be created with STATS_PERSISTENT=0 table option. During rolling-upgrade tables naturally already exists, thus we need to alter them to contain STATS_PERSISTENT=0 table option.
* | | MDEV-26571 : galera_sr.GCF-627 MTR failed: Result length mismatchJan Lindström2021-09-232-12/+8
| | | | | | | | | | | | | | | Test changes only: do not output mysql.wsrep_streaming_log contents.
* | | Merge 10.3 into 10.4Marko Mäkelä2021-09-2238-689/+738
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2021-09-2227-575/+311
| |\ \ | | |/
| | * MDEV-26450: Corruption due to innodb_undo_log_truncatebb-10.2-MDEV-26450Marko Mäkelä2021-09-229-123/+219
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At least since commit 055a3334adc004bd3a897990c2f93178e6bb5f90 (MDEV-13564) the undo log truncation in InnoDB did not work correctly. The main issue is that during the execution of trx_purge_truncate_history() some pages of the newly truncated undo tablespace could be discarded. fsp_try_extend_data_file(): Apply the peculiar rounding of fil_space_t::size_in_header only to the system tablespace, whose size can be expressed in megabytes in a configuration parameter. Other files may freely grow by a number of pages. fseg_alloc_free_page_low(): Do allow the extension of undo tablespaces, and mention the file name in the error message. mtr_t::commit_shrink(): Implement crash-safe shrinking of a tablespace file. First, durably write the log, then shrink the file, and finally release the page latches of the rebuilt tablespace. Refactored from trx_purge_truncate_history(). log_write_and_flush_prepare(), log_write_and_flush(): New functions to durably write log during mtr_t::commit_shrink().
| | * Silence a warning about unused Bison labelMarko Mäkelä2021-09-221-0/+3
| | |
| | * MDEV-26545 Spider does not correctly handle UDF and stored function in where ↵Daniel Ye2021-09-225-1/+418
| | | | | | | | | | | | | | | | | | conds - Handle stored function conditions correctly, with the same logic as with UDFs. - When running queries on Spider SE, by default, we do not push down WHERE conditions containing usage of UDFs/stored functions to remote data nodes, unless the user demands (by setting spider_use_pushdown_udf).
| | * MDEV-26441: Linux-dependent construct in SST scriptsbb-10.2-MDEV-26441-galeraJulius Goryavsky2021-09-203-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | SST scripts currently use Linux-specific construction to create a temporary directory if the path prefix for that directory is specified by the user. This does not work with FreeBSD. This commit adds support for FreeBSD. No separate test required.
| | * MDEV-26636: InnoDB defragmentation statistics cause races on TEMPORARY TABLEMarko Mäkelä2021-09-183-116/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | btr_defragment_save_defrag_stats_if_needed(): Do not save defragmentation statistics for temporary tables. They are exempt of defragmentation anyway (ha_innobase::optimize() never invokes defragmentation for them), and the user-visible names are not available inside InnoDB. Furthermore, InnoDB assumes that temporary tables are never accessed by other threads than the one that handles the session with which the temporary table is associated with. Furthermore, we simplify the test innodb.innodb_defrag_stats and include a test case that demonstrates that defragmentation statistics are no longer being saved for temporary tables.
| | * MDEV-15675 encryption.innodb_encryption failed in buildbot with timeoutbb-10.2-MDEV-15675Thirunarayanan Balathandayuthapani2021-09-172-3/+5
| | | | | | | | | | | | | | | Test case fail to include undo tablespace while waiting for the encryption thread to encrypt all existing tablespace
| | * Give less memory to get reliable error.Oleksandr Byelkin2021-09-162-3/+3
| | |
| | * MDEV-26622: man mysqldump - insert-ignore not insert-intoDaniel Black2021-09-161-5/+5
| | | | | | | | | | | | Thanks Karl Levik
| | * MDEV-26574 An improper locking bug due to unreleased lock in the ds_xbstream.ccVladislav Vaintroub2021-09-151-3/+7
| | | | | | | | | | | | release lock in all as cases n xbstream_open, also fix the case where malloc would return NULL.
| | * MDEV-26573 : A static analyzer warning about ds_archive.ccVladislav Vaintroub2021-09-154-318/+0
| | | | | | | | | | | | | | | This file had not been compiled for long time. Remove this from the tree.
| | * MDEV-25702 Auxiliary FTS table evicts during optimize tableThirunarayanan Balathandayuthapani2021-09-131-1/+2
| | | | | | | | | | | | | | | | | | | | | InnoDB could evict the fts auxiliary table in row_fts_merge_insert(). So bulk insert could be dealing with garbage FTS auxiliary table.Patch should delay closing the table in row_fts_merge_insert().
| * | MDEV-26545 Spider does not correctly handle UDF and stored function in where ↵Daniel Ye2021-09-227-7/+429
| | | | | | | | | | | | | | | | | | | | | conds - Handle stored function conditions correctly, with the same logic as with UDFs. - When running queries on Spider SE, by default, we do not push down WHERE conditions containing usage of UDFs/stored functions to remote data nodes, unless the user demands (by setting spider_use_pushdown_udf). - Disable direct update/delete when a udf condition is skipped.
| * | MDEV-26521 Remove mdev-504.testVladislav Vaintroub2021-09-212-104/+0
| | |
| * | MDEV-23506 mariadb-connector-c-devel package from standard RHEL 8 repo ↵bb-10.3-abychkoAlexey Bychko2021-09-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | conflicts with MariaDB's packages added alternative name for MariaDB-devel package to replace mariadb-connector-c-devel from RHEL 8 distribution. this patch is for 10.3+ on RHEL/Centos 8
| * | Fix Connect build with MSVC+NinjaVladislav Vaintroub2021-09-111-0/+1
| | |
* | | Fixed random failure of main.truncate_notembeddedMonty2021-09-212-2/+4
| | | | | | | | | | | | | | | The test depends on how the server allocates memory and may fail randomly. Fixed by accepting that TRUNCATE may work in some cases (happened to me)
* | | Updated main.alias test to fix max_lengthMonty2021-09-212-7/+7
| | | | | | | | | | | | | | | The test will work after libmariadb has been updated to return correct max_length for prepared statements
* | | Fixed max length calculation for embedded serverMonty2021-09-211-5/+7
| | | | | | | | | | | | | | | The old code did not take into account unsigned numbers when calculating max_lengths of fields.
* | | Fixed alias.test to also works with psMonty2021-09-172-7/+7
| | | | | | | | | | | | | | | | | | The issue is that max_length for prepared statements are different from normal queries, which can optimize the max_length based on the result length.
* | | MDEV-19950 addendum: galera_ssl_upgrade removed from the list of disabled ↵bb-10.4-MDEV-19950-addendum-galeraJulius Goryavsky2021-09-172-1/+3
| | | | | | | | | | | | tests and adapted for 10.4+
* | | MDEV-26053 : TRUNCATE on table with Foreign Key Constraint no longer ↵bb-10.4-truncateJan Lindström2021-09-176-23/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | replicated to other nodes Problem was that there was extra condition !thd->lex->no_write_to_binlog before call to begin TOI. It seems that this variable is not initialized. TRUNCATE does not support [NO_WRITE_TO_BINLOG | LOCAL] keywords, thus we should not check this condition. All this was hidden in a macro, so I decided to remove those macros that were used only a few places with actual function calls.
* | | MDEV-26621 assertion failue "index->table->persistent_autoinc" in ↵bb-10.4-kevgsEugene Kosov2021-09-163-1/+28
| | | | | | | | | | | | | | | | | | | | | /storage/innobase/btr/btr0btr.cc during IMPORT dict_index_t::clear_instant_alter(): when searhing for an AUTO_INCREMENT column don't skip the beginning of the list because the field can be at the beginning of the list
* | | MDEV-23519 Protocol packet - "Original Name" info is showing alias name,Monty2021-09-144-7/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | instead of original name of the column When doing refactoring of temporary table field creation a mistake was done when copying the column name when creating internal temporary tables. For internal temporary tables we should use the original field name, not the item name (= alias).
* | | MDEV-26601: mysys - O_TMPFILE ^ O_CREATDaniel Black2021-09-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Thanks to Fabian Vogt for noticing the mutual exclusions of these open flags on tmpfs caused by mariadb opening it incorrectly. As such we clear the O_CREAT flag while opening it as O_TMPFILE.
* | | MDEV-21613 Failed to open table mysql.wsrep_streaming_log for writingbb-10.4-MDEV-21613Daniele Sciascia2021-09-145-8/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix sporadic failure for MTR test galera_sr.GCF-1018B. The test sometimes fails due to an error that is logged to the error log unnecessarily. A deterministic test case (included in this patch) shows that the error is loggen when a transaction is BF aborted right before it opens the streaming log table to perform fragment removal. When that happens, the attempt to open the table fails and consequently an error is logged. There is no need to log this error, as an ER_LOCK_DEADLOCK error is returned to the client. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
* | | Merge branch '10.3' into 10.4Vladislav Vaintroub2021-09-113-16/+62
|\ \ \ | |/ /
| * | Merge branch '10.2' into 10.3Vladislav Vaintroub2021-09-113-16/+62
| |\ \ | | |/ | | | | | | | | | | | | # Conflicts: # cmake/os/Windows.cmake # sql/sql_yacc.yy
| | * MDEV-26527 speedup appveyor build - 10.2st-10.2-wlad-appveyorVladislav Vaintroub2021-09-111-15/+24
| | |