Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
912ca4c1
Commit
912ca4c1
authored
Aug 20, 2016
by
Alexey Yurchenko
Committed by
Sachin Setiya
Apr 06, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
GAL-401: MTR test for the fix.
parent
b6667321
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
0 deletions
+70
-0
mysql-test/suite/galera/r/GAL-401.result
mysql-test/suite/galera/r/GAL-401.result
+21
-0
mysql-test/suite/galera/t/GAL-401.test
mysql-test/suite/galera/t/GAL-401.test
+49
-0
No files found.
mysql-test/suite/galera/r/GAL-401.result
0 → 100644
View file @
912ca4c1
SET GLOBAL wsrep_provider_options = 'pc.ignore_sb=true';
SET @@global.wsrep_desync = 1;
SET SESSION wsrep_sync_wait=0;
SET GLOBAL wsrep_provider_options = 'gmcast.isolate=1';
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY, f2 CHAR(1));
SET GLOBAL wsrep_provider_options = 'gmcast.isolate=0';
SHOW STATUS LIKE 'wsrep_desync_count';
Variable_name Value
wsrep_desync_count 0
SET @@global.wsrep_desync = 0;
SET SESSION wsrep_sync_wait=7;
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f1` int(11) NOT NULL,
`f2` char(1) DEFAULT NULL,
PRIMARY KEY (`f1`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
DROP TABLE t1;
CALL mtr.add_suppression("WSREP: Protocol violation. JOIN message sender (.*) is not in state transfer \\(SYNCED\\). Message ignored.");
SET GLOBAL wsrep_provider_options = 'pc.ignore_sb=false';
mysql-test/suite/galera/t/GAL-401.test
0 → 100644
View file @
912ca4c1
# This tests proper desync counter cleanup when DONOR/DESYNC state is cleared.
--
source
include
/
galera_cluster
.
inc
--
source
include
/
have_innodb
.
inc
# Make node 1 tolerate split-brain
SET
GLOBAL
wsrep_provider_options
=
'pc.ignore_sb=true'
;
# Desync and disconnect node 2 from the PC:
--
connection
node_2
SET
@@
global
.
wsrep_desync
=
1
;
SET
SESSION
wsrep_sync_wait
=
0
;
SET
GLOBAL
wsrep_provider_options
=
'gmcast.isolate=1'
;
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
'non-Primary'
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_status'
;
--
source
include
/
wait_condition
.
inc
# Wait until node 2 disappears from the PC:
--
connection
node_1
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
1
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_size'
;
--
source
include
/
wait_condition
.
inc
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
'Primary'
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_status'
;
--
source
include
/
wait_condition
.
inc
# Modify app state to force node 2 into PRIMARY upon reconnection.
CREATE
TABLE
t1
(
f1
INTEGER
PRIMARY
KEY
,
f2
CHAR
(
1
));
# Reconnect node 2 to the PC:
--
connection
node_2
SET
GLOBAL
wsrep_provider_options
=
'gmcast.isolate=0'
;
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
'Primary'
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_status'
;
--
source
include
/
wait_condition
.
inc
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
2
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_size'
;
--
source
include
/
wait_condition
.
inc
# Must return 0:
SHOW
STATUS
LIKE
'wsrep_desync_count'
;
# Resync node_2, should pass:
SET
@@
global
.
wsrep_desync
=
0
;
SET
SESSION
wsrep_sync_wait
=
7
;
SHOW
CREATE
TABLE
t1
;
DROP
TABLE
t1
;
CALL
mtr
.
add_suppression
(
"WSREP: Protocol violation. JOIN message sender (.*) is not in state transfer
\\
(SYNCED
\\
). Message ignored."
);
--
connection
node_1
--
let
$wait_condition
=
SELECT
VARIABLE_VALUE
=
2
FROM
INFORMATION_SCHEMA
.
GLOBAL_STATUS
WHERE
VARIABLE_NAME
=
'wsrep_cluster_size'
;
--
source
include
/
wait_condition
.
inc
SET
GLOBAL
wsrep_provider_options
=
'pc.ignore_sb=false'
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment