MySQL 5.5 upgraded to MySQL5.6, in the absence of any changes in the case, directly to the data placed under the MySQL 5.6 Run, the beginning of all normal, but after a new database, assigning permissions, the error:
ERROR 2013 (HY000): Lost connection to MySQL server during query
At first I thought it was not connected to the socket because I saw the error at the same time:
Can ' t connect to the local MySQL server through socket '/var/lib/mysql/mysql.sock
But after viewing, found sock normal, no problem, and then ran to the official website below to see the MySQL 5.6 Upgrade guide, which has such a paragraph:
After upgrading to a new version of MySQL, Run Mysql_upgrade (click Section 4.4.7, "Mysql_upgrade-check and upgrade MySQL Tables "). This is checks your tables, and attempts to repair them if necessary. It also updates your grant tables to "sure" they have the current structure so, can take advantage any New capabilities. (Some releases of MySQL introduce changes to the structure of the "Grant tables to add" new privileges or features.)
Mysql_upgrade does not upgrade the contents to the Help tables. For upgrade instructions, click 5.1.10, "Server-side help".
Mysql_upgrade should not being used the server is running with--gtid-mode=on, since it could make changes in nontransacti Onal system tables in the MySQL database, many of which are MyISAM and cannot is changed to use a different storage . Gtid mode and Mysql_upgrade.
That's clear, execute it:
Mysql_upgrade-u root-p
After execution, the GRANT statement is executed before the problem is resolved.