With the CentOS project switching its focus to CentOS Stream, one of the alternatives that aim to function as a downstream build (building and releasing packages after they’re released by Red Hat) is Rocky Linux. This how-to shows how to install Percona Server for MySQL 8.0 on the Rocky Linux distribution.
You can get the information on the distribution release version by checking the /etc/redhat-release file:
|
1 |
[root@rocky ~]# cat /etc/redhat-release<br>Rocky Linux release 8.4 (Green Obsidian) |
Downloading and Installing the percona-release repository package for Red Hat Linux and derivatives:
|
1 |
[root@rocky ~]# yum install -y https://repo.percona.com/yum/percona-release-latest.noarch.rpm |
This should result in:
|
1 |
…<br><br>Verifying : percona-release-1.0-26.noarch 1/1<br>Installed:<br><br> percona-release-1.0-26.noarch<br><br>Complete! |
Once the repository package is installed, you should set up the Percona Server for MySQL 8.0 repository by running:
|
1 |
[root@rocky ~]# percona-release setup ps80 |
Please note that you’ll be prompted to disable the mysql module to install Percona Server packages:
|
1 |
* Disabling all Percona Repositories<br><br>On RedHat 8 systems it is needed to disable dnf mysql module to install Percona-Server<br><br>Do you want to disable it? [y/N] y<br><br>Disabling dnf module...<br><br>Percona Release release/noarch YUM repository 6.3 kB/s | 1.6 kB 00:00<br><br>Dependencies resolved.<br><br>=============================================================================<br><br>Package Architecture Version Repository Size<br><br>=============================================================================<br>Disabling modules:<br><br>mysql<br><br><br><br><br>Transaction Summary<br><br>==============================================================================<br>Complete!<br><br>dnf mysql module was disabled<br><br>* Enabling the Percona Server 8.0 repository<br><br>* Enabling the Percona Tools repository<br><br><*> All done! |
This part is also covered in the Percona Server for MySQL documentation.
1. Installing the latest Percona Server 8.0 binaries:
|
1 |
[root@rocky ~]# yum -y install percona-server-server |
This will also install all the required dependencies:
|
1 |
Installed:<br><br>compat-openssl10-1:1.0.2o-3.el8.x86_64 <br>libaio-0.3.112-1.el8.x86_64 <br>percona-server-client-8.0.23-14.1.el8.x86_64 <br>percona-server-server-8.0.23-14.1.el8.x86_64 <br>percona-server-shared-8.0.23-14.1.el8.x86_64 <br>percona-server-shared-compat-8.0.23-14.1.el8.x86_64<br><br>Complete! |
2. After installation is done, you can start the mysqld service:
|
1 |
[root@rocky ~]# systemctl start mysqld |
3. Once the service is running you can check the status by running:
|
1 |
[root@rocky ~]# systemctl status mysqld |
You should get similar output to:
|
1 |
● mysqld.service - MySQL Server <br>Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)<br><br> Active: active (running) since Mon 2021-06-28 10:23:22 UTC; 6s ago<br> Docs: man:mysqld(8)<br><br>http://dev.mysql.com/doc/refman/en/using-systemd.html<br>Process: 37616 ExecStartPre=/usr/bin/mysqld_pre_systemd (code=exited, status=0/SUCCESS)<br>Main PID: 37698 (mysqld)<br>Status: "Server is operational"<br>Tasks: 39 (limit: 23393)<br>Memory: 450.7M<br>CGroup: /system.slice/mysqld.service<br>└─37698 /usr/sbin/mysqld<br><br>Jun 28 10:23:12 rocky systemd[1]: Starting MySQL Server...<br>Jun 28 10:23:22 rocky systemd[1]: Started MySQL Server |
From this process, we can see that the installation on RockyLinux is the same as installing Percona Server for MySQL on CentOS/Red Hat.
Percona Distribution for MySQL is the most complete, stable, scalable, and secure, open-source MySQL solution available, delivering enterprise-grade database environments for your most critical business applications… and it’s free to use!
Resources
RELATED POSTS