mysql_upgrade — Check and Upgrade MySQL Tables For local host connections on Unix, the  --protocol=tcp  option forces a connection using TCP/IP rather than the Unix socket file. By default,  mysql_upgrade  runs as the MySQL  root  user. If the  root  password is expired when you run mysql_upgrade , it displays a message that your password is expired and that  mysql_upgrade  failed as a result. To correct this, reset the  root  password to unexpire it and run  mysql_upgrade  again. First, connect to the server as  root : Reset the password using  ALTER USER : Then exit  mysql  and run  mysql_upgrade  again: If you run the server with the  disabled_storage_engines  system variable set to disable certain storage engines (for example,  MyISAM ),  mysql_upgrade  might fail with an error like this: To handle this, restart the server with  disabled_storage_engines  disabled. Then you should be able to run  mysql_upgrade  successfully. After that, restart the server with  disabled_storage_engines  set to its original value. Unless invoked with the  --upgrade-system-tables  option,  mysql_upgrade  processes all tables in all user schemas as necessary. Table checking might take a long time to complete. Each table is locked and therefore unavailable to other sessions while it is being processed. Check and repair operations can be time-consuming, particularly for large tables. Table checking uses the  FOR UPGRADE  option of the CHECK TABLE  statement. For details about what this option entails, see Section 13.7.3.2, “CHECK TABLE Statement” . mysql_upgrade  marks all checked and repaired tables with the current MySQL version number. This ensures that the next time you run  mysql_upgrade  with the same version of the server, it can be determined whether there is any need to check or repair a given table again. mysql_upgrade  saves the MySQL version number in a file named  mysql_upgrade_info  in the data directory. This is used to quickly check whether all tables have been checked for this release so that table- checking can be skipped. To ignore this file and perform the check regardless, use the  --force  option. The  mysql_upgrade_info  file is deprecated; expect it to be removed in a future version of MySQL. mysql_upgrade  checks  mysql.user  system table rows and, for any row with an empty  plugin  column, sets that column to  ’mysql_native_password’  if the credentials use a hash format compatible with that plugin. Rows with a pre-4.1 password hash must be upgraded manually. mysql_upgrade  does not upgrade the contents of the time zone tables or help tables. For upgrade instructions, see Section 5.1.15, “MySQL Server Time Zone Support” , and Section 5.1.17, “Server-Side Help Support” . 405 Note Note mysql_upgrade: [ERROR] 3161: Storage engine MyISAM is disabled (Table creation is disallowed). shell>  mysql_upgrade [ options ] mysql>  ALTER USER USER() IDENTIFIED BY ’ root-password ’; shell>  mysql -u root -p Enter password:  **** <- enter root password here