1

I want to import a couple of huge .sql dumps (~600G each) into a mysql server 5.5 running on an Ubuntu 14.04.

The machine has about 8G of RAM allocated to it;

The previous machine had 128G;

Storage space considerations aside, what else should I take into account before performing the mysql import command?

5
  • Why start on such and old OS/MySQL version?
    – danblack
    Commented Sep 17, 2018 at 10:41
  • also read this entry
    – danblack
    Commented Sep 17, 2018 at 10:43
  • My previous (legacy) db is on 5.5 and I want to maintain the same version for the time being
    – pkaramol
    Commented Sep 17, 2018 at 10:51
  • InnoDB or MyISAM or both?
    – Rick James
    Commented Oct 7, 2018 at 16:44
  • Just InnoDB ...
    – pkaramol
    Commented Oct 7, 2018 at 17:07

2 Answers 2

1

If your database tables have them, it's always best to drop indices and recreate them after the import. Also, disable foreign keys temporarily by executing SET FOREIGN_KEY_CHECKS=0; (and SET FOREIGN_KEY_CHECKS=1; afterwards). This will speed up your import (though by how much is hard to tell).

1
  • Check the .sql files; those steps may be built in.
    – Rick James
    Commented Oct 7, 2018 at 16:44
0

For large-scale backup and restore, a physical backup is more appropriate, to copy the data files in their original format that can be restored quickly, and recommends the MySQL Enterprise mysqlbackup utility. -- http://dev.mysql.com/doc/refman/5.7/en/mysqldump.html#mysqldump-performance

Find Detailed Answer here: https://forums.mysql.com/read.php?24,645437,645443#msg-645443

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.