mirror of
https://github.com/MariaDB/server.git
synced 2026-05-07 07:35:32 +02:00
Cherry picking patch for BUG#37051
This commit is contained in:
parent
099a80d05a
commit
923f61039e
10 changed files with 503 additions and 30 deletions
23
mysql-test/include/wait_for_slave_sql_error_and_skip.inc
Normal file
23
mysql-test/include/wait_for_slave_sql_error_and_skip.inc
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
# ==== Purpose ====
|
||||
#
|
||||
# Wait for slave SQL error, skip the erroneous statement and restart
|
||||
# slave
|
||||
#
|
||||
# ==== Usage ====
|
||||
#
|
||||
# let show_sql_error=0|1;
|
||||
# source include/wait_for_slave_sql_error_and_skip.inc;
|
||||
|
||||
echo --source include/wait_for_slave_sql_error_and_skip.inc;
|
||||
connection slave;
|
||||
source include/wait_for_slave_sql_error.inc;
|
||||
if ($show_sql_error)
|
||||
{
|
||||
let $error= query_get_value("SHOW SLAVE STATUS", Last_SQL_Error, 1);
|
||||
echo Last_SQL_Error = $error;
|
||||
}
|
||||
|
||||
# skip the erroneous statement
|
||||
set global sql_slave_skip_counter=1;
|
||||
source include/start_slave.inc;
|
||||
connection master;
|
||||
Loading…
Add table
Add a link
Reference in a new issue