You may use one of the online-alter-table tools: these are specialized scripts which simulate an
ALTER TABLE operation, using
TRIGGERs and shadow tables, and which allow for non-interruptive process. Thus, they will copy your table in small chunks into a shadow table even while you are modifying (inserting, deleting, updating) your table, synching the two.
They end with a very brief (up to a few seconds, typically sub second) lock, where your original table is thrown away and the "shadow" table kicks in to replace it.
Two such tools are:
- oak-online-alter-table, as part of the openark-kit (disclosure: I'm author of this tool). Been around since 2009 and the first of its kind.
- pt-online-schema-change, as part of the percona-toolkit; later arrival but more sophisticated and more tested.