summaryrefslogtreecommitdiff
path: root/mysql-test/suite/galera
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-27181: Galera SST scripts should use ssl_capath for CA directorybb-10.6-MDEV-27181-galeraJulius Goryavsky2021-12-149-10/+758
| | | | | | | | | | | | | | | | | 1. Galera SST scripts should use ssl_capath (not ssl_ca) for CA directory. The current implementation tries to automatically detect the path using the trailing slash in the ssl_ca variable value, but this approach is not compatible with the server configuration. Now, by analogy with the server, SST scripts also use a separate ssl_capath variable. In addition, a similar tcapath variable has been added for the old-style configuration (in the "sst" section). 2. Openssl utility detection made more reliable. 3. Removed extra spaces in automatically generated command lines - to simplify debugging of the SST scripts. 4. In general, the code for detecting the presence or absence of auxiliary utilities has been improved - it is made more reliable in some configurations (and for shells other than bash).
* Merge 10.5 into 10.6Marko Mäkelä2021-12-0418-113/+100
|\
| * Merge 10.4 into 10.5Marko Mäkelä2021-12-0318-112/+100
| |\
| | * Fix bad galera testsJan Lindström2021-12-0118-112/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * galera_kill_applier : we should make sure that node has correct number of wsrep appliers * galera_bad_wsrep_new_cluster: This test restarts both nodes, so it is bad on mtr. Make sure it is run alone * galera_update_limit : Make sure we have PK when needed galera_as_slave_replay : bf abort was not consistent * galera_unicode_pk : Add wait_conditions so that all nodes are part of cluster and DDL and INSERT has replicated before any further operations are done. * galera_bf_abort_at_after_statement : Add wait_conditions to make sure all nodes are part of cluster and that DDL and INSERT has replicated. Make sure we reset DEBUG_SYNC.
* | | galera.galera_unicode_pk: Avoid MDL wait timeoutMarko Mäkelä2021-11-251-0/+1
| | |
* | | Merge 10.5 into 10.6Marko Mäkelä2021-11-258-0/+841
|\ \ \ | |/ /
| * | Merge 10.4 into 10.5Marko Mäkelä2021-11-258-0/+841
| |\ \ | | |/
| | * MDEV-26915: SST scripts do not take log_bin_index setting into accountJulius Goryavsky2021-11-233-0/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, SST scripts assume that the filename specified in the --log-bin-index argument either does not contain an extension or uses the standard ".index" extension. Similar assumptions are used for the log_bin_index parameter read from the configuration file. This commit adds support for arbitrary extensions for the index file paths.
| | * MDEV-26064: mariabackup SST fails when starting with --innodb-force-recoverybb-10.4-MDEV-26064-galeraJulius Goryavsky2021-11-235-0/+749
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the server is started with the --innodb-force-recovery argument on the command line, then during SST this argument can be passed to mariabackup only at the --prepare stage, and accordingly it must be removed from the --mysqld-args list (and it is not should be passed to mariabackup otherwise). This commit fixes a flaw in the SST scripts and add a test that checks the ability to run the joiner node in a configuration that uses --innodb-force-recovery=1.
| | * post merge result fixOleksandr Byelkin2021-11-021-0/+3
| | |
| | * Merge branch '10.3' into 10.4Oleksandr Byelkin2021-11-021-3/+0
| | |\
| | | * MDEV-23328 Server hang due to Galera lock conflict resolutionJan Lindström2021-11-024-13/+19
| | | | | | | | | | | | | | | | | | | | * Fix error handling NULL-pointer reference * Add mtr-suppression on galera_ssl_upgrade
| | | * MDEV-23328 Server hang due to Galera lock conflict resolutionsjaakola2021-10-297-25/+119
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mutex order violation when wsrep bf thread kills a conflicting trx, the stack is wsrep_thd_LOCK() wsrep_kill_victim() lock_rec_other_has_conflicting() lock_clust_rec_read_check_and_lock() row_search_mvcc() ha_innobase::index_read() ha_innobase::rnd_pos() handler::ha_rnd_pos() handler::rnd_pos_by_record() handler::ha_rnd_pos_by_record() Rows_log_event::find_row() Update_rows_log_event::do_exec_row() Rows_log_event::do_apply_event() Log_event::apply_event() wsrep_apply_events() and mutexes are taken in the order lock_sys->mutex -> victim_trx->mutex -> victim_thread->LOCK_thd_data When a normal KILL statement is executed, the stack is innobase_kill_query() kill_handlerton() plugin_foreach_with_mask() ha_kill_query() THD::awake() kill_one_thread() and mutexes are victim_thread->LOCK_thd_data -> lock_sys->mutex -> victim_trx->mutex 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 also fixed unprotected calls to wsrep_thd_abort that will use wsrep_abort_transaction. This is fixed by holding THD::LOCK_thd_data while we abort transaction. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * | MDEV-23328 Server hang due to Galera lock conflict resolutionJan Lindström2021-11-022-7/+13
| | | | | | | | | | | | | | | | | | | | * Fix error handling NULL-pointer reference * Add mtr-suppression on galera_ssl_upgrade
| | * | MDEV-23328 Server hang due to Galera lock conflict resolutionsjaakola2021-10-298-235/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mutex order violation when wsrep bf thread kills a conflicting trx, the stack is wsrep_thd_LOCK() wsrep_kill_victim() lock_rec_other_has_conflicting() lock_clust_rec_read_check_and_lock() row_search_mvcc() ha_innobase::index_read() ha_innobase::rnd_pos() handler::ha_rnd_pos() handler::rnd_pos_by_record() handler::ha_rnd_pos_by_record() Rows_log_event::find_row() Update_rows_log_event::do_exec_row() Rows_log_event::do_apply_event() Log_event::apply_event() wsrep_apply_events() and mutexes are taken in the order lock_sys->mutex -> victim_trx->mutex -> victim_thread->LOCK_thd_data When a normal KILL statement is executed, the stack is innobase_kill_query() kill_handlerton() plugin_foreach_with_mask() ha_kill_query() THD::awake() kill_one_thread() and mutexes are victim_thread->LOCK_thd_data -> lock_sys->mutex -> victim_trx->mutex 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 also fixed unprotected calls to wsrep_thd_abort that will use wsrep_abort_transaction. This is fixed by holding THD::LOCK_thd_data while we abort transaction. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * | MDEV-25114: Crash: WSREP: invalid state ROLLED_BACK (FATAL)Jan Lindström2021-10-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Revert "MDEV-23328 Server hang due to Galera lock conflict resolution" This reverts commit eac8341df4c3c7b98360f4e9498acf393dc055e3.
* | | | Merge branch '10.5' into 10.6Oleksandr Byelkin2021-11-022-7/+13
|\ \ \ \ | |/ / /
| * | | MDEV-23328 Server hang due to Galera lock conflict resolutionJan Lindström2021-11-022-7/+13
| | | | | | | | | | | | | | | | | | | | * Fix error handling NULL-pointer reference * Add mtr-suppression on galera_ssl_upgrade
| * | | MDEV-23328 Server hang due to Galera lock conflict resolutionsjaakola2021-10-298-235/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mutex order violation when wsrep bf thread kills a conflicting trx, the stack is wsrep_thd_LOCK() wsrep_kill_victim() lock_rec_other_has_conflicting() lock_clust_rec_read_check_and_lock() row_search_mvcc() ha_innobase::index_read() ha_innobase::rnd_pos() handler::ha_rnd_pos() handler::rnd_pos_by_record() handler::ha_rnd_pos_by_record() Rows_log_event::find_row() Update_rows_log_event::do_exec_row() Rows_log_event::do_apply_event() Log_event::apply_event() wsrep_apply_events() and mutexes are taken in the order lock_sys->mutex -> victim_trx->mutex -> victim_thread->LOCK_thd_data When a normal KILL statement is executed, the stack is innobase_kill_query() kill_handlerton() plugin_foreach_with_mask() ha_kill_query() THD::awake() kill_one_thread() and mutexes are victim_thread->LOCK_thd_data -> lock_sys->mutex -> victim_trx->mutex 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 also fixed unprotected calls to wsrep_thd_abort that will use wsrep_abort_transaction. This is fixed by holding THD::LOCK_thd_data while we abort transaction. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| * | | MDEV-25114: Crash: WSREP: invalid state ROLLED_BACK (FATAL)Jan Lindström2021-10-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Revert "MDEV-23328 Server hang due to Galera lock conflict resolution" This reverts commit eac8341df4c3c7b98360f4e9498acf393dc055e3.
* | | | Merge 10.5 into 10.6Marko Mäkelä2021-10-212-12/+15
|\ \ \ \ | |/ / /
| * | | Merge 10.4 into 10.5Marko Mäkelä2021-10-212-12/+15
| |\ \ \ | | |/ /
| | * | Merge 10.3 into 10.4Marko Mäkelä2021-10-212-12/+15
| | |\ \ | | | |/
| | | * Merge 10.2 into 10.3Marko Mäkelä2021-10-212-12/+15
| | | |\
| | | | * MDEV-26815 : galera.galera_ftwrl_drain fails with wrong errno 1146bb-10.2-MDEV-26815-galeraJan Lindström2021-10-132-12/+15
| | | | | | | | | | | | | | | | | | | | Add wait_conditions to stabilize
* | | | | Merge 10.5 into 10.6Marko Mäkelä2021-10-131-1/+0
|\ \ \ \ \ | |/ / / /
| * | | | MDEV-24062: : Galera test failure on galera_var_replicate_myisam_onbb-10.5-MDEV-24062-galeraJan Lindström2021-10-131-1/+0
| | | | | | | | | | | | | | | | | | | | 10.5 version
* | | | | Merge 10.5 into 10.6Marko Mäkelä2021-10-1310-220/+54
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | The changes to galera.galear_var_replicate_myisam_on in commit d9b933bec6061758c5d7b34f55afcae32a85c110 are omitted due to conflicts with commit 27d66d644cf2ebe9201e0362f2050036cce2908a.
| * | | | MDEV-24062: Re-disable the test after mergeMarko Mäkelä2021-10-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test galera.galera_var_replicate_myisam_on would trigger an assertion failure "mode() == m_local" in wsrep-lib/src/client_state.cpp after the merge of commit 3067ffc58e2ada6591e3d823b31841ea685da6c7 enabled it.
| * | | | Merge 10.4 into 10.5Marko Mäkelä2021-10-1312-230/+79
| |\ \ \ \ | | |/ / /
| | * | | MDEV-21518 : galera.galera_toi_ddl_nonconflicting MTR failed: 1213: Deadlock ↵Jan Lindström2021-10-081-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | found when trying to get lock Add wait condition.
| | * | | Update galera disabled.defJan Lindström2021-10-075-194/+1
| | | | |
| | * | | MDEV-22996 : Hang on galera_toi_truncate test caseJan Lindström2021-10-072-17/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Actual problem was earlier fixed. This contains only test case change. We use debug_sync to force concurrent DML and TRUNCATE.
| | * | | MDEV-24062 : Galera test failure on galera_var_replicate_myisam_onJan Lindström2021-10-072-6/+25
| | | | | | | | | | | | | | | | | | | | We should do after_statement only for local transactions.
| | * | | Fix galera_var_reject_queries test caseJan Lindström2021-10-072-12/+5
| | | | |
* | | | | Merge 10.5 into 10.6Marko Mäkelä2021-10-055-21/+128
|\ \ \ \ \ | |/ / / /
| * | | | Merge 10.4 into 10.5Marko Mäkelä2021-10-045-21/+128
| |\ \ \ \ | | |/ / /
| | * | | Merge 10.3 into 10.4Marko Mäkelä2021-10-042-21/+99
| | |\ \ \ | | | |/ /
| | | * | Merge 10.2 into 10.3Marko Mäkelä2021-10-042-21/+99
| | | |\ \ | | | | |/
| | | | * MDEV-24978 crash with transaction on table with no PK and long fulltext columnbb-10.2-MDEV-24978-galerasjaakola2021-09-302-21/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a table has no unique indexes, write set key information will be collected on all columns in the table. The write set key information has space only for max 3500 bytes for individual column, and if a varchar colummn of such non-primary key table is longer than this limit, currently a crash follows. The fix in this commit, is to truncate key values extracted from such long varhar columns to max 3500 bytes. This may potentially lead to false positive certification failures for transactions, which operate on separate cluster nodes, and update/insert/delete table rows, which differ only in the part of such long columns after 3500 bytes border. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
| | * | | MDEV-22708 Assertion `!mysql_bin_log.is_open() || ↵mkaruza2021-10-013-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | thd.is_current_stmt_binlog_format_row()' failed in Delayed_insert::handle_inserts and in Diagnostics_area::set_eof_status Variable wsrep_forced_binlog_format has higher priority than binlog_format. In situation where STATEMENT is used and DELAYED INSERT is executing we should fall back to non-delay INSERT. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
* | | | | Merge 10.5 into 10.6Marko Mäkelä2021-09-308-103/+58
|\ \ \ \ \ | |/ / / /
| * | | | Merge 10.4 into 10.5Marko Mäkelä2021-09-308-52/+58
| |\ \ \ \ | | |/ / / | | | | | | | | | | | | | | | FIXME: Part of the MDEV-20699 test is disabled due to nonderterministic result.
| | * | | Merge 10.3 into 10.4Marko Mäkelä2021-09-292-50/+21
| | |\ \ \ | | | |/ /
| | | * | Merge 10.2 into 10.3Marko Mäkelä2021-09-292-50/+21
| | | |\ \ | | | | |/
| | | | * Remove test from galera_fulltext until MDEV-24978 is fixed.bb-10.2-jan-galeraJan Lindström2021-09-272-50/+21
| | | | |
| | * | | 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.4 into 10.5Marko Mäkelä2021-09-242-51/+0
| |\ \ \ \ | | |/ / /
| | * | | Merge 10.3 into 10.4Marko Mäkelä2021-09-242-51/+0
| | |\ \ \ | | | |/ /