[MDEV-16728] RENAME temporary table may not find the target table on slave in RBR Created: 2018-07-11 Updated: 2023-04-27 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Data Definition - Temporary, Replication |
| Affects Version/s: | 10.2, 10.3, 10.4, 10.5, 10.6 |
| Fix Version/s: | 10.4, 10.5, 10.6 |
| Type: | Bug | Priority: | Major |
| Reporter: | Andrei Elkin | Assignee: | Andrei Elkin |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||||||||||
| Description |
|
In RBR operations on a tmp table are not binlogged, expect of currently DROP TEMPORARY TABLE IF EXISTS `tmp_table` which is motivated by a possibility of `some_name` Not being logged in RBR DROP TEMPORARY TABLE IF EXISTS `tmp_table_new` /* renamed table */ would be replicated not to find the target table on the slave and thus an orphan A way to fix this issue requires either add A multi-table RENAME (of list-of-table-pairs) needs some attention to prevent |
| Comments |
| Comment by Elena Stepanova [ 2019-05-31 ] | ||||||||||||||||||
|
See some test cases in MDEV-16909, those cause replication abort with ER_TABLE_EXISTS_ERROR (Table '...' already exists) and ER_NO_SUCH_TABLE (Table '...' doesn't exist). Here is another one, a little tricker, but still the general area:
Here CREATE TEMPORARY TABLE is written into the binary log, but RENAME is not, so the slave thinks it's still working with a temporary table, hence the error. |