Bug #68506 | Got SIGSEGV on MTS recovery + SQL thread error | ||
---|---|---|---|
Submitted: | 27 Feb 2013 7:23 | Modified: | 16 May 2013 17:14 |
Reporter: | Yoshinori Matsunobu (OCA) | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Replication | Severity: | S2 (Serious) |
Version: | 5.6.10 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[27 Feb 2013 7:23]
Yoshinori Matsunobu
[27 Feb 2013 7:24]
Yoshinori Matsunobu
I mistyped title:)
[27 Feb 2013 8:29]
MySQL Verification Team
After some effort I was able to crash 5.6.10 here: mysqld.exe!apply_event_and_update_pos()[rpl_slave.cc:3306] mysqld.exe!exec_relay_log_event()[rpl_slave.cc:3707] mysqld.exe!handle_slave_sql()[rpl_slave.cc:5516] mysqld.exe!pfs_spawn_thread()[pfs.cc:1856] mysqld.exe!pthread_start()[my_winthread.c:63] mysqld.exe!_callthreadstartex()[threadex.c:314] mysqld.exe!_threadstartex()[threadex.c:292] rli was 0x00000000 here: if (!(rli->is_mts_recovery() && bitmap_is_set(&rli->recovery_groups, rli->mts_recovery_index))) { reason= ev->shall_skip(rli); }
[27 Feb 2013 8:30]
MySQL Verification Team
And on debug build, I hit exact crash: mysqld-debug.exe!bitmap_is_set()[my_bitmap.h:101] mysqld-debug.exe!apply_event_and_update_pos()[rpl_slave.cc:3306] mysqld-debug.exe!exec_relay_log_event()[rpl_slave.cc:3701] mysqld-debug.exe!handle_slave_sql()[rpl_slave.cc:5516] mysqld-debug.exe!pfs_spawn_thread()[pfs.cc:1855] mysqld-debug.exe!pthread_start()[my_winthread.c:62] mysqld-debug.exe!_callthreadstartex()[threadex.c:314] mysqld-debug.exe!_threadstartex()[threadex.c:297]
[27 Feb 2013 8:37]
MySQL Verification Team
also repeatable on latest 5.6.11 from internal bzr.
[26 Mar 2013 16:58]
Manish Kumar
Hi Yoshinori, Will the attached patch fix your problem? Let me know if it does not. Thanks! === modified file 'sql/rpl_slave.cc' --- sql/rpl_slave.cc revid:saikumar.v@oracle.com-20130318054358-77zqaztvuroujo5s +++ sql/rpl_slave.cc revid:manish.4.kumar@oracle.com-20130318070143-ec45rxdkg37be0u2 @@ -5622,6 +5622,7 @@ if (rli->recovery_groups_inited) { bitmap_free(&rli->recovery_groups); + rli->mts_recovery_group_cnt= 0; rli->recovery_groups_inited= false; } Regards, Manish Kumar
[16 May 2013 17:14]
Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release. If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at http://dev.mysql.com/doc/en/installing-source.html
[16 May 2013 17:15]
Jon Stephens
Fixed in 5.6+. Documented as follows in the 5.6.12 and 5.7.2 changelogs: An SQL thread error during MTS slave recovery caused the slave to fail. Closed.
[24 May 2013 6:59]
MySQL Verification Team
http://bugs.mysql.com/bug.php?id=69126 marked as duplicate of this one.