Upgrade from 2.16 to 3.0.3 is failing

need some urgent help

we are trying to upgrade our piwik version from 2.16 to 3.0.3 and the db upgrade doesn’t seem to work. I am running it from the server and query updating this table in particular fails piwik_log_link_visit_action. our DB is 750 G and that table has 2 billion rows. after running for several hours it fails with this error ERROR 1034 (HY000): Incorrect key file for table ‘piwik_log_link_visit_action’; try to repair it. Is there another way to update this table ? I need to run two alter statements
ALTER TABLE piwik_log_link_visit_action ADD COLUMN idpageview CHAR(6) NULL DEFAULT NULL, ADD COLUMN interaction_position SMALLINT UNSIGNED DEFAULT NULL, MODIFY COLUMN time_spent_ref_action INTEGER(10) UNSIGNED NULL;
ALTER TABLE piwik_log_link_visit_action CHANGE idlink_va idlink_va BIGINT(10) UNSIGNED NOT NULL AUTO_INCREMENT, CHANGE idvisit idvisit BIGINT(10) UNSIGNED NOT NULL, CHANGE idaction_name_ref idaction_name_ref INTEGER(10) UNSIGNED NULL;

lplease help …the system is down for our users and can’t be used untill the DB upgrade is complete.

Hi. See if you have space in the TMP folder of the MySQL server .
If not run:
REPAIR TABLE tbl_name USE_FRM
Regards

I think its failing on the size. The table itself is 287GB and the database has only 250 GB free space. the alter command is trying to copy the data to another table and failing on the size limit. I will try to increase the storage and try to run the queries again. I wish the queries wouldn’t take hours to complete. I reverted back to older version of piwik for now.