File: rpl_source_pos_wait_after_startup.test

package info (click to toggle)
mysql-8.0 8.0.43-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,273,924 kB
  • sloc: cpp: 4,684,605; ansic: 412,450; pascal: 108,398; java: 83,641; perl: 30,221; cs: 27,067; sql: 26,594; sh: 24,181; python: 21,816; yacc: 17,169; php: 11,522; xml: 7,388; javascript: 7,076; makefile: 2,194; lex: 1,075; awk: 670; asm: 520; objc: 183; ruby: 97; lisp: 86
file content (61 lines) | stat: -rw-r--r-- 2,054 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
##############################################################################
# BUG#19507923: CANNOT DO POSITIONS SYNC WHEN AUTO_POSITION IS ON
#
# Purpose of the test:
#
# 1. Start replication with gtid-mode= on and master_auto_position= 1.
# 2. Execute DML and DDL on master and sync slave with master.
# 3. Re-start master with gtid-mode= on and master_auto_position= 1.
# 4. At slave, select source_pos_wait() with
#    pos= end log position of previous gtid log event in the latest
#    binary log at master.
# 5. Verify that the slave does not hang on sync with the master.
#

--source include/have_binlog_format_statement.inc

--echo #
--echo # Step 1: setup replication
--echo #
--let $rpl_skip_start_slave= 1
--source include/master-slave.inc

# Bug#23297190 :RPL_GTID_SERVER_SIGHUP AND RPL_SOURCE_POS_WAIT_AFTER_STARTUP FAILS
# IN VALGRIND : Increased the time interval between the connection retries.
--let $rpl_connection_name= slave
--source include/rpl_connection.inc
CHANGE REPLICATION SOURCE TO SOURCE_CONNECT_RETRY=30, SOURCE_RETRY_COUNT=30;
--source include/start_slave.inc

# Ensuring that prev_gtids_event will have some gtid after binlog rotation
--let $rpl_connection_name= master
--source include/rpl_connection.inc
create table t1 (a int);
Insert into t1 values(1);
drop  table t1;
--source include/sync_slave_sql_with_master.inc

--echo #
--echo # Step 2: restart Master
--echo #

--let $rpl_connection_name= master
--source include/rpl_connection.inc
--let $rpl_server_number= 1
--let $rpl_start_with_gtids= 1
--source include/rpl_restart_server.inc
--source include/wait_until_connected_again.inc

--echo #
--echo # Step 3: Wait on positions by setting ignore_gtids_on_sync= 1.
--echo #         The sync_slave_sql_with_master.inc will call SOURCE_POS_WAIT()
--echo #         internally verifying the fix.
--echo #

--let $rpl_connection_name= master
--source include/rpl_connection.inc
--let $ignore_gtids_on_sync= 1
--source include/sync_slave_sql_with_master.inc
--let $ignore_gtids_on_sync= 0

--source include/rpl_end.inc