Percona 5.6 Upgrade to 5.7 related error and workaround

Source: Internet
Author: User
Tags percona

This morning, the development environment of the MySQL upgrade to the 5.7.15,5.6 data import, start everything normal, check the. Err log, the following exception was found:

2016-10-31t00:29:33.187073z 0 [Warning] System table ' Time_zone_leap_second ' is expected to be transactional.
2016-10-31t00:29:33.187093z 0 [Warning] System table ' Time_zone_name ' is expected to be transactional.
2016-10-31t00:29:33.187097z 0 [Warning] System table ' Time_zone ' is expected to be transactional.
2016-10-31t00:29:33.187101z 0 [Warning] System table ' Time_zone_transition_type ' is expected to be transactional.
2016-10-31t00:29:33.187104z 0 [Warning] System table ' time_zone_transition ' is expected to be transactional.
2016-10-31t00:29:33.187690z 0 [Warning] System table ' servers ' is expected to be transactional.
2016-10-31t00:29:33.188536z 0 [Warning] Info table is isn't ready to be used. Table ' Mysql.slave_master_info ' cannot be opened.
2016-10-31t00:29:33.188827z 0 [Warning] Info table is isn't ready to be used. Table ' Mysql.slave_relay_log_info ' cannot be opened.
2016-10-31t00:29:33.195026z 0 [ERROR] incorrect definition of table mysql.db:expected column ' User ' at position 2 to has Type char (+), found type char (16).
2016-10-31t00:29:33.195055z 0 [ERROR] mysql.user have no ' event_priv ' column at position 28
2016-10-31t00:29:33.195236z 0 [ERROR] Event Scheduler:an error occurred when initializing system tables. Disabling the Event Scheduler.

Perform mysql_update to upgrade.

The relevant 5.7 incompatible MySQL parameters include the following:

max_statement_time=300000

innodb_log_block_size=4096

Another problem is that service MySQL stop cannot delete the ${hostname}.pid file after service MySQL start is started, and see that the Mysql.server file provided by Support-files is also available in RM *. PID command, after the later to see where the problem.

In addition, some of the other common changes are as follows:

1, in MySQL 5.6, the beginning of the InnoDB monitoring method (this mysqld hang,mysql client itself can not log in to the time is very useful) as follows:

Use MySQL;

CREATE TABLE Innodb_monitor (a INT) Engine=innodb;

Under MySQL 5.7, adjust to the following:

Set GLOBAL innodb_status_output=on;

2, the normal creation of users, change the password way to close to the Oracle syntax:

5.6:

Grant all on * * to [e-mail protected] ' 172.18.% ' identified by "password";

Set password for [email protected] ' 172.18.% ' =password (' password ');

5.7:

create user [email protected] ' 172.18.% ' identified by ' [email protected]# ';

Alter user [email protected] ' 172.18.% ' identified by ' [email protected]# ';--user must already exist

Percona 5.6 Upgrade to 5.7 related error and workaround

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.