How to monitor MySQL / MariaDB query progress
spinellis.gr
spinellis.gr
The article is MariaDB specific.
You create a copy of the table with an updated set of indexes and copy the data over into the new table. I think Percona even has a utility that will copy all the next data over via stored procedure that is getting written to the table.
> Several ALTER TABLE operations can be performed without copying the table, without blocking inserts, updates, and deletes to the table, or both. These enhancements are known collectively as online DDL. See Section 14.13, “InnoDB and Online DDL” for details.
https://dev.mysql.com/doc/refman/5.7/en/innodb-online-ddl-op...