You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug#37189985: Crashing and widespread corruption of spatial indexes
after INPLACE alter table
ANALYSIS
ALTER TABLE, INPLACE operation on a table containing both a spatial
index and an auto increment column can cause corruption. This is due
to auto increment column value getting overwritten in the old records
of spatial index while preparing the new record.
The records are accessed through a cursor, cached into a tuple vector
m_dtuple_vec in the index_tuple_info_t::add(). The row is built with
shallow copying of fields, and the auto-increment value is prepared
locally and copied. This process repeats until page traversal is
complete. In subsequent iterations, shallow-copied pointers are
overwritten, but since the source record remains intact and page is
latched, they stay valid. The row continues to reference the old
auto-incremented value, causing only the auto-increment field to be
overwritten, and older rows to point to the latest auto-incremented
value.
FIX
Perform deep copy of the auto-increment field while processing
the spatial index records.
Note: This is a 5.7 patch.
Change-Id: Ib8852ef5977d881bf06dadcc35d41acfa760c96f
0 commit comments