MySQL How to optimize the repair database table

Source: Internet
Author: User
Tags mysql client phpmyadmin

  Recent customer problems said that the site because the database error cannot open, oneself summed up some experience, and then read the wrong information as follows :

   

    MySQL database as a good open source database version, support large data storage. However, if too many operations are used, the frequent operation of the table may cause problems with the database tables that need to be optimized and repaired

     Fix Table-" method one:

In the browser, hit phpMyAdmin or run the following command on the MySQL client:

1) Directly run SQL statements REPAIR table ' table_name ' repair tables, as follows:

          

            

         2) find operations in the database can also repair the table, specific operations such as:

           

        Fix Table --" method two:

You can clear the current database directly, restore the previously backed up user information, this method is slower, of course, it is not recommended to use this method, if you have previously backed up user information.

If it is only a single repair, it will not be long after the table is damaged, at this time, it is recommended to optimize your table, I simply summed up the way to optimize the table, here is just a simple method oh, but practical, specific methods are as follows:

Optimization Table--"Method one:

          In the browser, hit phpMyAdmin or run the following command on the MySQL client:

1) Directly run SQL statements OPTIMIZE table ' table_name ' repair tables, as follows:

                

MySQL How to optimize the repair database table

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.