Home >Database >Mysql Tutorial >Upgrading MySQL using the MySQL Yum repository

Upgrading MySQL using the MySQL Yum repository

WBOY
WBOYforward
2023-08-27 10:33:021058browse

使用 MySQL Yum 存储库升级 MySQL

Let us know how to upgrade MySQL with the help of MySQL Yum repository -

MySQL can be upgraded using MySQL Yum repository. Let's look at the steps required for this upgrade. By default, the MySQL Yum repository updates MySQL to the latest version in the release series selected by the user during installation

To update to a different release series, the subrepository for the selected series needs to be disabled. The next step is to enable the sub-repository for the target family. It is recommended to upgrade from one series to the next rather than skipping a series.

Use yun to upgrade MySQL

You can use the following commands to update MySQL and its components. Make sure that dnf is not enabled on these platforms -

sudo yum update mysql-server

For platforms with dnf enabled, use the following command -

sudo dnf upgrade mysql-server

Alternatively, this can be done by telling Yum to update everything on the user's system Update MySQL, but this will take more time. To do this on platforms without dnf enabled, use the following command -

sudo yum update

For platforms with dnf enabled, use the following command -

sudo dnf upgrade

MySQL must be restarted after updating with Yum server. After the server is restarted, you need to run the "mysql_upgrade" command to check and resolve incompatibility issues between the old data and the upgraded software.

Upgrade specific components

Specific components can also be upgraded. To do this, first use the following command to list all packages of the MySQL component. This is for systems that support dnf -

sudo dnf list installed | grep "^mysql"

For systems that do not have dnf enabled, use the following command -

sudo yum list installed | grep "^mysql"

After determining the package name, for platforms that do not have dnf enabled, use the following command to update Package-

sudo yum update package-name

For platforms that support dnf-

sudo dnf upgrade package-name

The above is the detailed content of Upgrading MySQL using the MySQL Yum repository. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:tutorialspoint.com. If there is any infringement, please contact admin@php.cn delete