Bug #100156 | XA COMMIT still work after stop group_replication | ||
---|---|---|---|
Submitted: | 8 Jul 2020 10:30 | Modified: | 8 Jul 2020 15:21 |
Reporter: | phoenix Zhang (OCA) | Email Updates: | |
Status: | Duplicate | Impact on me: | |
Category: | MySQL Server: XA transactions | Severity: | S3 (Non-critical) |
Version: | 8.0.18, 8.0.20 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | group_replication, xa |
[8 Jul 2020 10:30]
phoenix Zhang
[8 Jul 2020 10:33]
phoenix Zhang
test file, need move to mysql-test/suite/group_replication/t
Attachment: gr_xa_commit_read_only_bug.test (application/octet-stream, text), 894 bytes.
[8 Jul 2020 10:35]
phoenix Zhang
run the test-case with below command: ./mtr group_replication.gr_xa_commit_read_only_bug --nocheck-testcase The output will be: include/group_replication.inc [rpl_server_count=2] Warnings: Note #### Sending passwords in plain text without SSL/TLS is extremely insecure. Note #### Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information. [connection server1] [connect conn1] select * from performance_schema.replication_group_members; CHANNEL_NAME MEMBER_ID MEMBER_HOST MEMBER_PORT MEMBER_STATE MEMBER_ROLE MEMBER_VERSION group_replication_applier 3a436cd6-c106-11ea-becb-c8f7507e5048 127.0.0.1 13000 ONLINE PRIMARY 8.0.18 group_replication_applier 3a43bcef-c106-11ea-a1ed-c8f7507e5048 127.0.0.1 13001 ONLINE PRIMARY 8.0.18 SELECT @@super_read_only; @@super_read_only 0 CREATE TABLE t1 (c1 INT NOT NULL PRIMARY KEY, c2 INT); INSERT INTO t1 VALUES (1,1); [connect conn1_1] XA START '1'; INSERT INTO t1 VALUES (2,2); XA END '1'; XA PREPARE '1'; [connect conn1_2] STOP GROUP_REPLICATION; SELECT @@super_read_only; @@super_read_only 1 INSERT INTO t1 VALUES (3,3); ERROR HY000: The MySQL server is running with the --super-read-only option so it cannot execute this statement XA COMMIT '1'; SELECT * FROM t1; c1 c2 1 1 2 2 From above result, after STOP GROUP_REPLICATION, @@spuer_read_only become on, and cannot do INSERT. While XA COMMIT success.
[8 Jul 2020 11:27]
MySQL Verification Team
Hello phoenix Zhang! Thank you for the report. regards, Umesh
[8 Jul 2020 15:21]
Nuno Carvalho
Duplicate of BUG#91646: xa command still operation when super_read_only is true