1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-07 00:04:31 +03:00
Commit Graph

1751 Commits

Author SHA1 Message Date
Oleksandr Byelkin
89c7e2b9c7 Merge branch '10.11' into 11.4 2025-06-17 09:50:22 +02:00
Marko Mäkelä
3da36fa130 Merge 10.6 into 10.11 2025-05-26 08:10:47 +03:00
Marko Mäkelä
1c7209e828 Merge 10.6 into 10.11 2025-05-21 07:36:35 +03:00
Jan Lindström
497d6324bc MDEV-36627 : galera.MDEV-29142: certification position less than last commited
After the membership change on a newly synced node, then this is just a
warning and safe to suppress.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-05-20 20:59:10 +02:00
Hemant Dangi
d38558f99b MDEV-36117: MDL BF-BF conflict on ALTER and UPDATE with multi-level foreign key parents
Issue:
Mariadb acquires additional MDL locks on UPDATE/INSERT/DELETE statements
on table with foreign keys. For example, table t1 references t2, an
UPDATE to t1 will MDL lock t2 in addition to t1.
A replica may deliver an ALTER t1 and UPDATE t2 concurrently for
applying. Then the UPDATE may acquire MDL lock for t1, followed by a
conflict when the ALTER attempts to MDL lock on t1. Causing a BF-BF
conflict.

Solution:
Additional keys for the referenced/foreign table needs to be added
to avoid potential MDL conflicts with concurrent update and DDLs.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-05-20 20:59:10 +02:00
Jan Lindström
a96367bc67 MDEV-36620 post-fix: galera_toi_ddl_nonconflicting test failure
Add wait_condition to wait until all inserted rows are replicated
so that show create table is deterministic.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-05-20 20:59:10 +02:00
Julius Goryavsky
2350295643 MDEV-36740: galera.galera_ssl_upgrade fails due to expired certificate
The certificate used in tests has been renewed.
2025-05-20 12:33:36 +02:00
Jan Lindström
d7457b4076 MDEV-36628 : galera_vote_during_ist test failed
Test changes only. Added wait_conditions to wait for expected
database state.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-05-20 12:30:40 +02:00
Oleksandr Byelkin
a8d4642375 Merge branch '10.11' into 11.4 2025-04-26 10:53:02 +02:00
Oleksandr Byelkin
4d41ec081e Merge branch '10.6' into 10.11 2025-04-26 10:47:03 +02:00
Oleksandr Byelkin
19644f6821 Merge branch '10.5' into 10.6 2025-04-26 10:41:52 +02:00
Jan Lindström
2f5c260f55 MDEV-36514 : galera_var_ignore_apply_errors test failure: table doesn't exist
Test changes only. Added proper wait_conditions to wait for expected
replication state.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-23 18:45:57 +02:00
Jan Lindström
76938eda9d MDEV-36625 : galera.galera_var_replicate_myisam_on test failure
Test case changes only. Add proper wait_conditions to wait expected
database state.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-23 18:45:11 +02:00
Jan Lindström
fe25a30a92 MDEV-36620 : galera_toi_ddl_nonconflicting test failure
Test changes only. Idea of the test is to test two concurrent
nonconflicting DDL-clauses. Therefore, use debug sync to
really execute two DDL-clauses as concurrently as Galera
allows.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-23 08:31:10 +02:00
Jan Lindström
67b6f9f285 MDEV-36618 : galera.galera_as_slave_nonprim test: result content mismatch
Remove unnecessary sleeps and use wait_for_slave_to_stop instead.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-22 20:46:51 +02:00
Julius Goryavsky
1a013cea95 Merge branch '10.6' into '10.11' 2025-04-16 03:34:40 +02:00
Julius Goryavsky
0403f0147f MDEV-33136: backport corrections from 10.11+ 2025-04-15 01:51:32 +02:00
Julius Goryavsky
88dfa6bcee Merge branch '10.5' into '10.6' 2025-04-15 01:49:48 +02:00
Julius Goryavsky
08f902e9ce MDEV-36116: correction for error codes 2025-04-14 18:20:25 +02:00
Alexey Yurchenko
77391482bd MDEV-34998: master can stop responding after cluster vote to evict a node
Additional corrections: there is a natural race between closing connection
to cluster in case of applying error and finishing the IST and sometimes
IST finishes and tries to send JOIN message over a closed connection.
This does not affect the correctness of the test or node behavior.
Added error message suppression.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-14 18:20:25 +02:00
Julius Goryavsky
bbd0e4b2c9 MDEV-34998 addendum: post-fix corrections for SST scripts
Delaying scripts on joiner after SST/IST has been made
a common debug feature for all suitable SST/IST methods.

Also some minor fixes have been made for new tests.
2025-04-14 18:20:25 +02:00
Alexey Yurchenko
ec5068fe59 MDEV-34998: master can stop responding after cluster vote to evict a node
After cluster vote to evict a node that failed a transaction,
current master can't commit anymore.

Error voting for joiner in the JOINED state was broken because
the group-wide commit cut (implicit SUCCESS vote) was not taken
into account when processing error vote request from the JOINED
node.

This commit adds 3 MTR tests to verify the fix in the galera
library works as designed.

Requires Galera library commit 91f0090a05e96c3cc353b80d961ede45cefb9279
(galera library version > 26.4.19).

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-14 18:20:25 +02:00
Marko Mäkelä
3ae8f114e2 Merge 10.11 into 11.4 2025-04-02 10:15:08 +03:00
Julius Goryavsky
74f0b99edf Merge branch '10.6' into '10.11' 2025-04-02 06:33:39 +02:00
Julius Goryavsky
b983a911e9 galera mtr tests: synchronization between branches and editions 2025-04-02 04:50:11 +02:00
Julius Goryavsky
03c31ab099 Merge branch '10.5' into '10.6' 2025-04-02 04:43:24 +02:00
Jan Lindström
25737dbab7 MDEV-33850 : For Galera, create sequence with low cache got signal 6 error: [ERROR] WSREP: FSM: no such a transition REPLICATING -> COMMITTED
Problem was that transacton was BF-aborted after certification
succeeded and transaction tried to rollback and during
rollback binlog stmt cache containing sequence value reservations
was written into binlog.

Transaction must replay because certification succeeded but
transaction must not be written into binlog yet, it will
be done during commit after the replay.

Fix is to skip binlog write if transaction must replay and
in replay we need to reset binlog stmt cache.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-02 04:29:40 +02:00
Denis Protivensky
dd54ce9e10 MDEV-36116: Remove debug assert in TOI when executing thread is killed
Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-04-02 04:29:40 +02:00
Julius Goryavsky
fa55b36c1e galera tests: corrections for garbd-related tests 2025-04-02 04:29:40 +02:00
Julius Goryavsky
41565615c5 galera: synchronization changes to stop random test failures 2025-04-02 04:29:34 +02:00
Marko Mäkelä
f5bd250f5b Merge 10.11 into 11.4 2025-03-28 13:55:21 +02:00
Julius Goryavsky
c61345169a galera tests: synchronization after merge 2025-03-28 02:53:59 +01:00
Marko Mäkelä
9a6540cb84 MDEV-29445 fixup: galera_sst_mariabackup_use_memory
The mariadb-backup --use-memory parameter will be trimmed to a multiple
of 8 MiB, or 2 MiB on 32-bit systems.

Also, let us remove a bogus message in mariadb-backup:
Warning: option 'use-memory': signed value -1 adjusted to 8388608
2025-03-27 08:54:00 +02:00
Marko Mäkelä
d68f5ea9f0 MDEV-35000 fixup: galera.MDEV-33136
TRUNCATE TABLE will no longer cause a reload of InnoDB statistics.
RENAME TABLE will.
2025-03-27 08:19:40 +02:00
Marko Mäkelä
ab0f2a00b6 Merge 10.6 into 10.11 2025-03-27 08:01:47 +02:00
Julius Goryavsky
15139c88a8 Merge branch '10.5' into '10.6' 2025-03-05 01:54:40 +01:00
Julius Goryavsky
3a4c0295ae galera: synchronization between branches and editions 2025-03-05 01:47:15 +01:00
Marko Mäkelä
49a6baec56 Merge 10.11 into 11.4 2025-03-03 11:07:56 +02:00
Julius Goryavsky
3deac2ea77 galera_inject_bf_log_wait mtr test: more stable test
Added explicit checkpoint wait instead of implicit assumption
that statement sent via --send will already be executed when
lock-contesting statement is started in another session.
2025-02-28 20:09:10 +01:00
Julius Goryavsky
e3d7d5ca26 Merge branch '10.5' into '10.6' 2025-02-27 04:02:33 +01:00
Julius Goryavsky
04d731b6cc galera mtr tests: synchronization between versions
Added fixes to galera tests for issues found during
merging changes from 10.5 to 10.6.
2025-02-26 18:19:28 +01:00
Marko Mäkelä
0c204bfb87 Merge 10.6 into 10.11 2025-02-25 10:23:24 +02:00
Jan Lindström
b167730499 MDEV-34891 : SST failure occurs when gtid_strict_mode is enabled
Problem was that initial GTID was set on wsrep_before_prepare
out-of-order. In practice GTID was set to same as previous
executed transaction GTID. In recovery valid GTID was found
from prepared transaction and this transaction is committed
leading to fact that same GTID was executed twice.

This is fixed by setting invalid GTID at wsrep_before_prepare
and later in wsrep_before_commit actual correct GTID is set
and this setting is done while we are in commit monitor i.e.
assigment is done in order of replication.

In recovery if prepared transaction is found we check its
GTID, if it is invalid transaction will be rolled back
and if it is valid it will be committed.

Initialize gtid seqno from recovered seqno when
bootstrapping a new cluster.

Added two test cases for both mariabackup and rsync SST methods
to show that GTIDs remain consistent on cluster and that
all expected rows are in the table.

Added tests for wsrep GTID recovery with binlog on and off.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-02-18 19:30:04 +01:00
Jan Lindström
94ef07d61e MDEV-32631 : galera_2_cluster: before_rollback(): Assertion `0' failed
Test case changes only. Add wait_conditions to make sure
nodes rejoin the cluster. Assertion itself should not be
possible anymore as we do not allow sequences on
Aria tables.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-02-18 04:51:16 +01:00
Julius Goryavsky
573b584eba galera mtr tests: unification of wsrep provider settings 2025-02-12 13:37:03 +01:00
Jan Lindström
bb64a51037 MDEV-35941 : galera_bf_abort_lock_table fails with wait for metadata lock
Problem was missing case from wsrep_handle_mdl_conflict. Test case
was trying to confirm that LOCK TABLE thread is not BF-aborted.
However as case was missing it was BF-aborted. Test case passed
because BF-aborting takes time and used wait condition might
see expected thread status before it was BF-aborted. Test naturally
failed if BF-aborting was done early enough.

Fix is to add missing case for SQLCOM_LOCK_TABLES to
wsrep_handle_mdl_conflict.

Note that using LOCK TABLE is still not recomended on cluster
because it could cause cluster hang.

This is a 10.5 specific commit that will then be overridden by
another one for 10.6+.

Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2025-02-12 13:35:47 +01:00
Julius Goryavsky
7b040e53cc galera mtr tests: fixes for test failures, 'cosmetic' changes and unification between versions 2025-02-12 12:25:09 +01:00
Julius Goryavsky
c35b6f133a galera mtr tests: synchronization between editions/branches (10.5) 2025-02-12 12:25:09 +01:00
Julius Goryavsky
dd5dc92a19 galera_sequences test: post-fix after MDEV-33245 2025-02-12 12:25:09 +01:00
Julius Goryavsky
c9a6adba1e galera mtr tests: synchronization of tests between branches 2025-02-12 11:30:14 +01:00