How to install older versions of MySQL
table of contents
Hello! This is Shimeji from the System Solutions Department.
He has been transferred to the SRE team since December, and is doing his best despite the confusion.
As the title suggests, you would like to install an older version of MySQL, but the repository may not be provided on the official website.
In such a case, please install it by following the steps below.
(The example below installs MySQL5.7.)
Download RPM Bundle file from official website
Download the RPM Bundle file of your desired version from the download page.
MySQL download page
wget https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.24-1.el7.x86_64.rpm-bundle.tar
Extracting files
Once the download is complete, unzip it.
tar -xvf mysql-5.7.24-1.el7.x86_64.rpm-bundle.tar
local installation
Locally install the RPM package you downloaded locally.
→ Please locally install the following using yum.
・mysql-community-server
・mysql-community-client
・mysql-community-common
・mysql-community-devel
・mysql-community-libs
・mysql-community-libs-compat
yum localinstall mysql-community-server-5.7.24-1.el7.x86_64.rpm mysql-community-client-5.7.24-1.el7.x86_64.rpm mysql-community-common-5.7.24-1.el7. x86_64.rpm mysql-community-devel-5.7.24-1.el7.x86_64.rpm mysql-community-libs-5.7.24-1.el7.x86_64.rpm mysql-community-libs-compat-5.7.24-1 .el7.x86_64.rpm
confirmation
Installation completed!
[root@localhost src]# mysql --version mysql Ver 14.14 Distrib 5.7.24, for Linux (x86_64) using EditLine wrapper
summary
I myself had trouble installing an older version of MySQL, so I hope this article is helpful to someone.
Thank you for your continued support this year.