From 84dbd0253d10ac210993de3a138ff38fb5c5315f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Tue, 27 Jun 2023 09:12:38 +0300 Subject: [PATCH] MDEV-31487: Recovery or backup failure after innodb_undo_log_truncate=ON recv_sys_t::parse(): For undo tablespace truncation mini-transactions, remember the start_lsn instead of the end LSN. This is what we expect after commit 461402a56432fa5cd0f6d53118ccce23081fca18 (MDEV-30479). --- storage/innobase/log/log0recv.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/innobase/log/log0recv.cc b/storage/innobase/log/log0recv.cc index 16022c8dd0e..1b62b1fe111 100644 --- a/storage/innobase/log/log0recv.cc +++ b/storage/innobase/log/log0recv.cc @@ -1951,9 +1951,9 @@ same_page: TRX_SYS_MAX_UNDO_SPACES, "compatibility"); /* The entire undo tablespace will be reinitialized by innodb_undo_log_truncate=ON. Discard old log for all pages. */ - trim({space_id, 0}, recovered_lsn); + trim({space_id, 0}, start_lsn); truncated_undo_spaces[space_id - srv_undo_space_id_start]= - { recovered_lsn, page_no }; + { start_lsn, page_no }; if (undo_space_trunc) undo_space_trunc(space_id); #endif