diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-12-04 15:00:57 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-12-04 15:34:28 +0200 |
commit | 95e903261e6fe120c572570fe6557fd57e01fae0 (patch) | |
tree | 1c5f24f3cdb468ea1e6fb4bcd7cde20150634b98 /storage/innobase/include | |
parent | e5dfdc5606829c092ccc0a13f4e138617e49e0fe (diff) | |
download | mariadb-git-95e903261e6fe120c572570fe6557fd57e01fae0.tar.gz |
MDEV-21216 InnoDB does dirty read of TRX_SYS page before recovery
InnoDB startup was discovering undo tablespaces in a dirty way.
It was reading a possibly stale copy of the TRX_SYS page before
processing any redo log records.
srv_start(): Do not call buf_pool_invalidate(). Invoke
trx_rseg_get_n_undo_tablespaces() after the recovery has been initiated.
recv_recovery_from_checkpoint_start(): Assert that the buffer pool is
empty. This used to be guaranteed by the buf_pool_invalidate() call.
trx_rseg_get_n_undo_tablespaces(): Move to the calling compilation unit,
and reimplement in a simpler way.
srv_undo_tablespace_create(): Remove the constant parameter
size=SRV_UNDO_TABLESPACE_SIZE_IN_PAGES.
srv_undo_tablespace_open(): Reimplement in a cleaner way, with
more robust error handling.
srv_all_undo_tablespaces_open(): Split from srv_undo_tablespaces_init().
srv_undo_tablespaces_init(): Read all "undo001","undo002" tablespace
files directly, without consulting the TRX_SYS page via calling
trx_rseg_get_n_undo_tablespaces().
This is joint work with Thirunarayanan Balathandayuthapani.
Diffstat (limited to 'storage/innobase/include')
-rw-r--r-- | storage/innobase/include/trx0rseg.h | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/storage/innobase/include/trx0rseg.h b/storage/innobase/include/trx0rseg.h index 29405997e5d..937e05dfba6 100644 --- a/storage/innobase/include/trx0rseg.h +++ b/storage/innobase/include/trx0rseg.h @@ -85,17 +85,6 @@ trx_rseg_create(ulint space_id) void trx_temp_rseg_create(); -/******************************************************************** -Get the number of unique rollback tablespaces in use except space id 0. -The last space id will be the sentinel value ULINT_UNDEFINED. The array -will be sorted on space id. Note: space_ids should have have space for -TRX_SYS_N_RSEGS + 1 elements. -@return number of unique rollback tablespaces in use. */ -ulint -trx_rseg_get_n_undo_tablespaces( -/*============================*/ - ulint* space_ids); /*!< out: array of space ids of - UNDO tablespaces */ /* Number of undo log slots in a rollback segment file copy */ #define TRX_RSEG_N_SLOTS (srv_page_size / 16) |