diff options
author | aelkin/elkin@koti.dsl.inet.fi <> | 2008-02-05 17:36:26 +0200 |
---|---|---|
committer | aelkin/elkin@koti.dsl.inet.fi <> | 2008-02-05 17:36:26 +0200 |
commit | 51b33ea35d065541c80829b73ee3f8a94c4826b8 (patch) | |
tree | e1668ec99a7e35aeab4d58e746ceeb131328729e /sql/slave.h | |
parent | 69fdf6794a35fcedce884769c9fc32570fa726b1 (diff) | |
download | mariadb-git-51b33ea35d065541c80829b73ee3f8a94c4826b8.tar.gz |
Bug #34305 show slave status handling segfaults when slave io is about
to leave
The artifact was caused by
a flaw in concurrent accessing the slave's io thd by
the io itself and a handling show slave status thread.
Namely, show_master_info did not acquire mi->run_lock mutex that is
specified for mi->io_thd member.
Fixed with deploying the mutex locking and unlocking. The mutex is kept
short time and without interleaving with mi->data_lock mutex.
Todo: to report and fix an issue with
sys_var_slave_skip_counter::{methods}
seem to acquire incorrectly
active_mi->rli.run_lock
instead of the specified
active_mi->rli.data_lock
A test case is difficult to compose, so rpl_packet should continue serving
as the indicator.
Diffstat (limited to 'sql/slave.h')
-rw-r--r-- | sql/slave.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/slave.h b/sql/slave.h index e7d4456ccd9..c61787cdf3b 100644 --- a/sql/slave.h +++ b/sql/slave.h @@ -65,8 +65,8 @@ mi->rli does not either. In MASTER_INFO: run_lock, data_lock - run_lock protects all information about the run state: slave_running, and the - existence of the I/O thread (to stop/start it, you need this mutex). + run_lock protects all information about the run state: slave_running, thd + and the existence of the I/O thread to stop/start it, you need this mutex). data_lock protects some moving members of the struct: counters (log name, position) and relay log (MYSQL_LOG object). |