Hint: optimizing Innodb bulk data loading
https://dev.mysql.com/doc/refman/5.0/en/optimizing-innodb-bulk-data-loading.html:
SET autocommit=0;
SET unique_checks=0;
SET foreign_key_checks=0;
... SQL import statements ...
SET unique_checks=1;
SET foreign_key_checks=1;
COMMIT;