“This is the sixth day of my participation in the First Challenge 2022. For details: First Challenge 2022”

Environment description

Current version: 8.0.17 Old version installation method:.zip file decompression + command line generation related configuration system environment: Windows10Copy the code

The preparatory work

  1. Back up the required DB database for data recovery in case of operation failure

  2. Download the latest installation package in zip format from mysql’s official website. The latest version is 8.0.28

To upgrade

  1. Stop the running mysql service

  1. Directly overwrite the contents of the new mysql8.0.28 file into the locally installed mysql8.0.17 folder

  1. After the file replacement is complete, restart the mysql service and log in to mysql to check the latest version

Mysql > update mysql > update mysql > update mysql > update mysql > update mysql > update mysql > update mysql

See everything is normal, then I declare: upgrade success!

episode

Mysql > update mysql > update mysql > update mysql > update mysql > update mysql > update mysql

I was a little panicked and thought I’d just delete the mysql/data folder and re-initialize the data folder

But when deleting, the prompt is as follows:

Occupied?? Does that mean it’s in service? How about shutting down the service? Complete command line operation record:

It was a close call, and it was very quick to start the service again. The first time it didn’t start successfully, it was supposed to do some initialization operations.

Pay attention to the upgrade

Content translated from official documents

  • Supports upgrades from MySQL 5.7 to 8.0. However, upgrades are only supported between generic (GA) versions. For MySQL 8.0, you need to upgrade from MySQL 5.7 GA version (5.7.9 or later). Upgrading from non-GA versions of MySQL 5.7 is not supported.
  • It is recommended to upgrade to the latest version before moving to the next version. For example, upgrade to the latest MySQL 5.7 version before upgrading to MySQL 8.0.
  • Version skipping is not supported. For example, upgrading directly from MySQL 5.6 to 8.0 is not supported.
  • Upgrades (from one GA version to another GA version) are supported within the release series once the release series has reached universal (GA) status. For example, from MySQLX 8.0.Upgrade to the8.0. YYes. (Upgrades involving non-GA versions in development status are not supported.) Version skipping is also supported. For example, from MySQLX 8.0.Upgrade to the8.0. ZIs supported (skip8.0. YVersion). MySQL8.0.11MySQL 8.0 is the first GA-state release in the MySQL 8.0 series.