Commit 1078a630 authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-22139 fseg_free_page_low() fails to write FREE_PAGE record, breaking recovery

This bug was introduced by MDEV-15528
commit a35b4ae8.

In the case that I analyzed, we failed to apply
an EXTENDED,INSERT_REUSE_REDUNDANT redo log record whose
preceding record points to unallocated area after PAGE_HEAP_TOP.

Had we properly written the FREE_PAGE record for the page,
recovery would have processed it, because during the checkpoint,
the log had been completely written past the LSN of the missed write.

fseg_free_page_low(): Always invoke mtr_t::free().
The other call is in fsp_free_page().
parent abb0a31e
......@@ -2605,6 +2605,8 @@ fseg_free_page_low(
xdes, xoffset, mtr);
fsp_free_extent(space, offset, mtr);
}
mtr->free(page_id_t(space->id, offset));
}
#ifndef BTR_CUR_HASH_ADAPT
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment