I'm currently uploading one of Wikipedia's dump files. It has 1GB compressed and ~7GB uncompressed. It has been importing it for 6 hours already. The size of the imported table in MySQL is at the moment 1.5GB(data+indexes). Will it continue to import until the size of the table will reach 7GB?

Note: The data directory of the database in on an external HDD. Considering this is only a development, so I'm not concerned by the real performance.


Can't say about the size, but you could try and check for the last entry or the amount of entries in the dump and then check for the current last entry in your database. This might help you determine the time the import will take till it finishes.

The size of the imported data might even get bigger than the uncompressed 7GB, since the indexes are usually not contained in dumps but get built on insert.

As a sidenote: This is also a way to speed up the import itself: drop the index during import and rebuild it later on, this helped me several times to speed things up.

  • ok, it reached the point where one insert takes 60 seconds. How am I supposed to drop the index during the import in a 7gb large file? Do you know of any program that could open such a file? – Andrew Jan 31 '12 at 9:10
  • 2
    first you need to open a new connection, you also could use MySql Workbench (mysql.com/products/workbench) now: SHOW INDEXES FROM tbl_name; gives you a list of all indexes on a table DROP INDEX index_name ON tbl_name removes an index – Benjamin Seiller Jan 31 '12 at 10:46
  • 2
    concerning the file viewer: i asume you are using Windows? Have a look here superuser.com/questions/34749/… or here stackoverflow.com/questions/159521/…, otherwise (Linux) less will work like a charm. – Benjamin Seiller Jan 31 '12 at 10:50
  • +1 for offhanded comment about dropping indexes prior to insert. – Derek Downey Jan 31 '12 at 20:32
  • 1
    @Andrew: hehe, you're welcome - but wait thanking me any more till you recreate the index ;) – Benjamin Seiller Feb 1 '12 at 12:01

I assume you are connected by ssh or you are sitting right at the computer. Open a separate window and run this query in mysql:


I was just doing an import of a 3GB (uncompressed) db the other day and I believe that was the query that showed me exactly where the import was in its progress.

In my case, the tables were being imported in alphabetical order, so I knew exactly where it was in its progress.

Also, check out this stackoverflow question's answers for killing process vs killing query.

  • if there is a process I'd like to kill? Is there a way to do it? There's a query I ran a while ago and is still not finished. – Andrew Jan 31 '12 at 8:56
  • 2
    Yes you can do that. I believe the id shown in SHOW PROCESSLIST corresponds to the PID. You can also check "top" to confirm. If you know the process id (pid), e.g. 407, you can use this simple command in the command line (just don't kill the wrong one): kill 407 – Buttle Butkus Jan 31 '12 at 9:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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