Home Tech News Upgrade Mysql 5.6 to 5.7 linux

Upgrade Mysql 5.6 to 5.7 linux


Upgrade Mysql 5.6 to 5.7 linuxUpgrade Mysql 5.6 to 5.7 linux

Here we can see “Upgrade Mysql 5.6 to 5.7 linux”

MySQL : Upgrade MySQL 5.6 to 5.7

This report summarizes the actions necessary to carry out an in-place update of MySQL 5.6 to 5.7. There are quite a few requirements and caveats related to this procedure, which means you need to confirm the documentation before trying an update.

Do a clean shutdown of the mysqld support.

# mysql --user root --password --execute="set global innodb_fast_shutdown=0"  # service mysqld stop

Take a physical copy at this time. This will let you recovery if anything fails. Additionally, have a copy of your “/etc/my. cnf” file.

You must get a great backup and exercise your restoration situation before attempting this. When something goes wrong, you will likely have to reinstall MySQL 5.6 and reestablish your database before trying again. You’ll need copies to get this done!

Install the MySQL 5.7 repository and then use YUM to upgrade the binaries.

# rpm -Uvh /tmp/mysql57-community-release-el6-7.noarch.rpm  # yum update mysql-community-server -y

The setup of this repository bundle fails with dependency errors, then delete the present applications and set up the newest new edition.

# yum remove mysql-community-server -y  # rpm -Uvh /tmp/mysql57-community-release-el6-7.noarch.rpm  # yum install mysql-community-server -y

This provides all of the packages on it, in order the next will be upgraded.

  • mysql-community-server
  • mysql-community-client
  • mysql-community-common
  • mysql-community-libs
  • mysql-community-libs-compat
  • Start the mysqld service.
# service mysqld start

Update database by conducting the mysql upgrade command. Before you do so, you may want to divert the output into your script, so it is possible to check for mistakes.

# script /tmp/upgrade.txt  # mysql_upgrade --password  Enter password:  Checking if update is needed.  Checking server version.  Running queries to upgrade MySQL server.  Checking system database.  mysql.columns_priv                                 OK  mysql.db                                           OK  mysql.engine_cost                                  OK  mysql.event                                        OK  mysql.func                                         OK  mysql.general_log                                  OK  mysql.gtid_executed                                OK  mysql.help_category                                OK  mysql.help_keyword                                 OK  mysql.help_relation                                OK  mysql.help_topic                                   OK  mysql.innodb_index_stats                           OK  mysql.innodb_table_stats                           OK  mysql.ndb_binlog_index                             OK  mysql.plugin                                       OK  mysql.proc                                         OK  mysql.procs_priv                                   OK  mysql.proxies_priv                                 OK  mysql.server_cost                                  OK  mysql.servers                                      OK  mysql.slave_master_info                            OK  mysql.slave_relay_log_info                         OK  mysql.slave_worker_info                            OK  mysql.slow_log                                     OK  mysql.tables_priv                                  OK  mysql.time_zone                                    OK  mysql.time_zone_leap_second                        OK  mysql.time_zone_name                               OK  mysql.time_zone_transition                         OK  mysql.time_zone_transition_type                    OK  mysql.user                                         OK  Upgrading the sys schema.  Checking databases.  mydatabase1.mytable_1                              OK  ...  mydatabase1.mytable_x                              OK  sys.sys_config                                     OK  mydatabase2.mytable_1                              OK  ...  mydatabase2.mytable_x                              OK  Upgrade process completed successfully.  Checking if update is needed.  #  # # end script command using exit.  # exit  #

Assess the “/tmp/upgrade.txt” document for mistakes. When that’s OK, the update is now complete. It might make sense to choose an additional backup now.


Please enter your comment!
Please enter your name here