Parsing mysql database restoration Error: (mysql Error Code: 1005 errno 121)

Source: Internet
Author: User

The reason is that the primary key must be unique, that is, there may be duplicates in the database with the current restored database. a restriction that Foreign Keys shoshould be uniquely named throughout the database, an effective method is to clear the original database and then create and restore it.

The reason for this is that the newly installed mysql ibdata1 backup file was changed to the ibdata1 backup file of the previous database. I wanted to use this method to forcibly restore it, but I didn't do it, as a result, an error occurred while restoring the database with the backup SQL file. You can restore the replaced ibdata1 file back.

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.