0

Our main database (MySQL) has about 50 tables with about 2 million records each, many of the columns are indexed. Before doing any major change, we either copy the entire DB under a new name like "DB_MAIN_Nov112018" and just leave it there as an online backup/copy or we copy individual tables and use the same principle. Does this hurt the performance of the database server as it has to do the indexing of the original DB as well as the many tables and databases that are used as backups?

  • Do you ask copying hurts performance or doing back up ? – igelr Nov 13 '18 at 6:47
  • The question is a little strange... Any (absolutely any!) additional operation (ever not DBServer-related) decreases performance. – Akina Nov 13 '18 at 7:21
  • 1
    Use mysqldump to create backups rather than making copies of the databases on the running server. If you need to restore things it's easy and quick to use the backups that you created. – Dave Nov 13 '18 at 12:54
0

As long as the database and its tables and many indexes are just sitting there, there is essentially no harm:

  • The extra db and tables have no impact on your ordinary queries.
  • Some meta operation involving the information_schema will notice them.
  • The copy takes disk space. (So would a dump.)

An advantage over a dump: You can quickly perform a query on the old copy.

| improve this answer | |

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.