When mysql imports the database, the error 1840 solution is returned. mysql1840

Source: Internet
Author: User

When mysql imports the database, the error 1840 solution is returned. mysql1840

1. symptom

When mysql imports a database using an SQL file, the ERROR 1840 (HY000) at line 24: @ GLOBAL. GTID_PURGED can only be set when @ GLOBAL. GTID_EXECUTED is empty.

Note: the mysql database has just been installed and has never been configured with master-slave replication or GTID.

2. Solution

After checking the online materials, I found that the following method can solve my problem.

Enter mysql mode and reset the master

# Mysql-u root-p

Enter Password

Mysql> reset master;

After exiting, re-import the data. OK. Let the machine import the data on its own.

 

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.