Big database: upgrade and cleanup issues

Hi,
we upgraded our Piwik instance from 2.1.7 (AFAIR) to 3.1.1. piwik_log_link_visit_action has around 20GB, so I assume we forgot to activate the automatic purge options, core:archive is run every night.
Running core:update took 2 weeks and now piwiks says we still need a database upgrade, which is running now:

  Executing ALTER TABLE `piwik_log_conversion` MODIFY COLUMN `visitor_days_since_first` SMALLINT(5) UNSIGNED NULL, MODIFY COLUMN `visitor_days_since_order` SMALLINT(5) UNSIGNED NULL, MODIFY COLUMN `visitor_returning` TINYINT(1) NULL, MODIFY COLUMN `visitor_count_visits` INT(11) UNSIGNED NOT NULL, MODIFY COLUMN `config_device_brand` VARCHAR( 100 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL, MODIFY COLUMN `config_device_model` VARCHAR( 100 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL, MODIFY COLUMN `config_device_type` TINYINT( 100 ) NULL DEFAULT NULL, MODIFY COLUMN `location_country` CHAR(3) NULL, MODIFY COLUMN `location_latitude` decimal(9, 6) DEFAULT NULL, MODIFY COLUMN `location_longitude` decimal(9, 6) DEFAULT NULL;... Done. [89 / 3]

I found an old blog entry which could fix this big update manually, but then mysql opens to many tables.

Regards
bjo