3 # Sync all servers, stop all slaves, restart all servers with
4 # GTID_MODE=ON and start the slaves up again.
6 # This is a temporary solution until we make GTID_MODE dynamic.
10 # First, make sure you understand the restrictions implied by turning
11 # on GTIDs. In particular, myisam updates are not supported so if you
12 # need to call mtr.add_suppression you should do it before sourcing
13 # this file. Then do the following (normally you don't need to use
14 # any of the parameters).
16 # [--let $rpl_gtid_mode_off= 1]
17 # [--let $rpl_server_parameters= --arg ...]
18 # [--let $rpl_skip_sync= 1]
19 # [--let $rpl_skip_stop_slave= 1]
20 # [--let $rpl_skip_stop_server= 1]
21 # [--let $rpl_skip_start_slave= 1]
22 # [--let $rpl_only_running_threads= 1]
23 # [--let $rpl_debug= 1]
24 # --source include/rpl_set_gtid_mode.inc
27 # $rpl_gtid_mode_off= 1
28 # Starts the server with gtid_mode=OFF, not ON.
30 # $rpl_server_parameters
31 # Any extra --server-parameters you want to pass to mysqld.
33 # $rpl_skip_stop_server
34 # By default, this script stops the server, assuming it is
35 # running. If the server is already stopped, set
36 # $rpl_no_stop_server=1 to inhibit this step.
39 # Do not sync the slaves before stopping the slave.
41 # $rpl_only_running_threads
42 # See include/rpl_sync.inc
44 # $rpl_skip_stop_slave
45 # Do not stop the slaves before stopping the server.
47 # $rpl_skip_start_slave
48 # Do not start the slaves again after starting the server.
51 # See include/rpl_init.inc
53 --let $include_filename= rpl_set_gtid_mode.inc
54 --source include/begin_include_file.inc
58 --source include/rpl_sync.inc
60 if (!$rpl_skip_stop_slave)
62 --source include/rpl_stop_slaves.inc
65 --let $rpl_start_with_gtids= 1
66 if ($rpl_gtid_mode_off)
68 --let $rpl_start_with_gtids= 0
71 --let $rpl_server_number= 1
72 while ($rpl_server_number <= $rpl_server_count)
74 if (!$rpl_skip_stop_server)
76 --source include/rpl_stop_server.inc
78 --source include/rpl_start_server.inc
79 --inc $rpl_server_number
82 if (!$rpl_skip_start_slave)
84 --source include/rpl_start_slaves.inc
87 --let $include_filename= rpl_set_gtid_mode.inc
88 --source include/end_include_file.inc