Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Innovation/trunk: PS-9107 : [ERROR] [MY-013183] [InnoDB] Assertion failure: ibuf0ibuf.c… #5268

Merged
merged 1 commit into from
Mar 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion storage/innobase/ibuf/ibuf0ibuf.cc
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ this program; if not, write to the Free Software Foundation, Inc.,
#include "sync0sync.h"

#include "my_dbug.h"
#include "scope_guard.h"

#if defined UNIV_DEBUG || defined UNIV_IBUF_DEBUG
bool srv_ibuf_disable_background_merge;
Expand Down Expand Up @@ -3812,7 +3813,14 @@ static bool ibuf_restore_pos(
return true;
}

if (fil_space_get_flags(space) == UINT32_UNDEFINED) {
/* Check if the tablespace is dropped. */
fil_space_t *sp = fil_space_acquire_silent(space);

auto guard = create_scope_guard([&]() {
if (sp != nullptr) fil_space_release(sp);
});

if (sp == nullptr || sp->flags == UINT32_UNDEFINED) {
/* The tablespace has been dropped. It is possible
that another thread has deleted the insert buffer
entry. Do not complain. */
Expand Down
Loading