From a33220fbefed74d9a63514e29914abc9896c6331 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Mon, 7 Aug 2017 13:50:31 +0300 Subject: [PATCH] MDEV-13451 Assertion `!recv_no_ibuf_operations' failed in ibuf_page_low() During InnoDB startup, change buffer merge operations are prohibited before recv_apply_hashed_log_recs(true), which performs the last phase of redo log apply. Before this call, ibuf_init_at_db_start() would be invoked, and it could trigger the debug assertion. ibuf_init_at_db_start(): Do not declare the mini-transaction as "inside change buffer", because nothing is being written in the mini-transaction. The purpose of this function is only to initialize the memory data structures from the persistent data structures. --- storage/innobase/ibuf/ibuf0ibuf.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/storage/innobase/ibuf/ibuf0ibuf.cc b/storage/innobase/ibuf/ibuf0ibuf.cc index b4cbe7d448088..d021f8c008591 100644 --- a/storage/innobase/ibuf/ibuf0ibuf.cc +++ b/storage/innobase/ibuf/ibuf0ibuf.cc @@ -534,7 +534,6 @@ ibuf_init_at_db_start(void) fseg_n_reserved_pages(header_page + IBUF_HEADER + IBUF_TREE_SEG_HEADER, &n_used, &mtr); - ibuf_enter(&mtr); ut_ad(n_used >= 2); @@ -556,7 +555,7 @@ ibuf_init_at_db_start(void) mutex_exit(&ibuf_mutex); ibuf->empty = page_is_empty(root); - ibuf_mtr_commit(&mtr); + mtr.commit(); ibuf->index = dict_mem_index_create( "innodb_change_buffer", "CLUST_IND",