A
A
Anton B2017-12-08 18:21:04
MySQL
Anton B, 2017-12-08 18:21:04

Is it possible to optimize InnoDB for fast INSERT?

Hello.
I have a DELL server (12 cores, RAM 128Gb, ​​SSD RAID1) + MySQL 5.5
And just a VPS on DigitalOcean (4 CPUs, RAM 32Gb, SSD) + MariaDB 10.1
There is table.sql (InnoDB, table size after import 14GB).
Importing this table on both servers takes 1-1.5 hours!
It seems to me that this is very slow, the dump takes a few minutes, and the restoration takes an hour.
Now I use the following settings (came to them via mysql.com)
innodb_flush_log_at_trx_commit = 0 (during import)
innodb_buffer_pool_size = 80G and 20G (DELL and VPS)
innodb_flush_neighbors = 0 (since SSD)
innodb_io_capacity = 1000
innodb_flush_method = O_DIRECT
Question:where else to dig to significantly reduce the time of importing large tables?
Thank you!

Answer the question

In order to leave comments, you need to log in

3 answer(s)
E
evnuh, 2017-12-08
@evnuh

Delete indexes before import, re-create after import.
PS Do you understand the difference between dripping and digging?

B
Boris Korobkov, 2017-12-08
@BorisKorobkov

It seems to me that this is very slow, the dump takes a few minutes, and the restoration takes an hour.

"Soon the fairy tale is told, but the deed is not done soon"
How to quickly fill in a large dump in mysql?

A
Astrohas, 2017-12-08
@Astrohas

service mysql restart --innodb-doublewrite=0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question