diff options
author | unknown <knielsen@knielsen-hq.org> | 2013-10-29 11:52:16 +0100 |
---|---|---|
committer | unknown <knielsen@knielsen-hq.org> | 2013-10-29 11:52:16 +0100 |
commit | f2799c68286c5742b5dbdeb65942494ff2ba38af (patch) | |
tree | 65ad9950132e6008d50965c1fb003f51a4df3975 /sql/rpl_parallel.cc | |
parent | 2fbd1c730735cfd857b250e3afb909290ab4821d (diff) | |
download | mariadb-git-f2799c68286c5742b5dbdeb65942494ff2ba38af.tar.gz |
MDEV-5195: Race when switching relay log causing crash
In parallel replication, when the IO thread switches relay log,
the SQL thread re-opens the current relaylog and seeks to the
current position. There was a race that would cause it to
sometimes seek to the wrong position, causing corruption and
crash.
Diffstat (limited to 'sql/rpl_parallel.cc')
-rw-r--r-- | sql/rpl_parallel.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sql/rpl_parallel.cc b/sql/rpl_parallel.cc index bbc917b6e9d..97e115cc79f 100644 --- a/sql/rpl_parallel.cc +++ b/sql/rpl_parallel.cc @@ -835,6 +835,7 @@ rpl_parallel::do_event(rpl_group_info *serial_rgi, Log_event *ev, /* Queue the event for processing. */ + rli->event_relay_log_pos= rli->future_event_relay_log_pos; cur_thread->enqueue(qev); mysql_mutex_unlock(&cur_thread->LOCK_rpl_thread); mysql_cond_signal(&cur_thread->COND_rpl_thread); |