separate doublewrite buffer should use SRV_EXTRA_SYS_SPACE_FIRST_ID instead of SRV_LOG_SPACE_FIRST_ID more

Bug #1078201 reported by Laurynas Biveinis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.1
Won't Fix
Low
Unassigned
5.5
Triaged
Low
Unassigned
5.6
Invalid
Undecided
Unassigned
5.7
Invalid
Undecided
Unassigned

Bug Description

Stock InnoDB uses SRV_LOG_SPACE_FIRST_ID as the upper bound for the allowed table tablespace ids. Since the separate doublewrite buffer allocates a high tablespace id as reserver for the separate buffer, it introduces SRV_EXTRA_SYS_SPACE_FIRST_ID that is less than SRV_LOG_SPACE_FIRST_ID.

But not all the code has been converted to use the proper boundary in checks:
1) fil_mutex_enter_and_prepare_for_io
2) fil_assign_new_space_id
3) fil_set_max_space_id_if_bigger - it is not clear, callers must be analyzed. Perhaps SRV_EXTRA_SYS_SPACE_FIRST_ID should be already fatal.
4) fil_create_new_single_table_tablespace
5) _fil_io
6) fil_aio_wait
7) dict_table_set_corrupt_by_space
8) buf_page_io_complete

Tags: xtradb
Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :

Benign in regular operation, might become fatal or even data corrupting when actual tablespace count approaches the upper bound.

Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :

Alternative fix (for 5.6 perhaps) is to allocate low space id instead, after the undo seg space ids.

tags: added: xtradb
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-2833

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.