Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.6.22, 10.11.15
-
None
-
None
-
Redhat 8.10
Description
We have 3 nodes Galera clusters with 2 db nodes and a arbitrator such that
arbitrator: version: 4-26.4.22
DB node 1: version 10.6.22
DB node 2: upgraded to 10.11.15
We are performaning upgrade the version from 10.6.22 to 10.11.15 using rolling upgrade in the intermediate stage so that node 2 is upgraded to 1011.15 and node 1 is still 10.6.22.
We have the follwoing siutuation :
- A sequence object is created with
CREATE SEQUENCE test_seq CACHE 10; - we have a table test_tbl with primary key id values using the test_seq:
CREATE TABLE test_tbl (
id BIGINT NOT NULL PRIMARY KEY,
node_name varchar(10),
timestamp datetime
); - we insert table test_tbl in both nodes currently by:
INSERT INTO test_tbl (id, node_name, timestamp)
VALUES (NEXT VALUE FOR test_seq, <node1/node2>, now());
- It has table result like:
id node_name timestamp
1 node1 10:00:01
2 node1 10:00:02
11 node2 10:00:03
12 node2 10:00:04
21 node1 10:00:05
22 node1 10:00:06
31 node2 10:00:07
32 node2 10:00:08
41 node1 10:00:09
42 node1 10:00:10
33 node2 10:00:11
34 node2 10:00:12
43 node1 10:00:13
44 node1 10:00:14
35 node2 10:00:15
36 node2 10:00:16
37 node2 10:00:17
38 node2 10:00:18
45 node1 10:00:19
39 node2 10:00:20
40 node2 10:00:21
<At 10:00:22, node 2 insert with id=41 which collided with the record at 10:00:09> (Duplicate key error)
Please note that from 10:00:09 onwards, node 1 kept generating the id 4X but node 2 still kept generate the id 3X (not 5X). Finally at 10:00:22, node2 tried to insert record with id=41 which collided the key at 10:00:09.
Read from the binary logs of both DB nodes, it is found that at 10:00:09 node1 updated the "next_not_cached_value " of test_seq but it wasn't replicated to node 2. However before 10:00:09, the update of next_not_cached_value was replicated to the other node successfully.
Also, during 10:00:09 to 10:00:21, we encountered deadlock error when inserting the records.