Installing Percona Server for MySQL on Red Hat Enterprise Linux and CentOS

Ready-to-use packages are available from the Percona Server for MySQL software repositories and the download page. The Percona yum repository supports popular RPM-based operating systems, including the Amazon Linux AMI.

The easiest way to install the Percona Yum repository is to install an RPM that configures yum and installs the Percona GPG key.

Specific information on the supported platforms, products, and versions are described in Percona Software and Platform Lifecycle.

Percona Server for MySQL is certified for Red Hat Enterprise Linux 8. This certification is based on common and secure best practices, and successful interoperability with the operating system. Percona Server is listed in the Red Hat Ecosystem Catalog.

What’s in each RPM package?

Each of the Percona Server for MySQL RPM packages have a particular purpose.

Package Contains
percona-server-server Server itself (the mysqld binary)
percona-server-debuginfo Debug symbols for the server
percona-server-client Command line client
percona-server-devel Header files needed to compile software using the client library.
percona-server-shared Client shared library.
percona-server-shared-compat Shared libraries for software compiled against old versions of the client library. The following libraries are included in this package:,,,, and
percona-server-test Includes the test suite for Percona Server for MySQL.

Installing Percona Server for MySQL from Percona yum repository

You can install Percona yum repository by running the following commands as a root user or with sudo.

  1. Install the Percona repository

    $ sudo yum install

    You should see an output that the files are being downloaded, like the following:

    percona-release-latest.noarch-rpm               36 kB/s | 19 kb 00:00
      Package         Architecture      Version    Repository    Size
       percona release    noarch         1.0-25     @commandline  19k
  2. Enable the repository:

    $ sudo percona-release setup ps80
    On RedHat 8 systems it is needed to disable dnf mysql module to install Percona-Server
    Do you want to disable it? [y/N] y
  3. Install the packages

    $ sudo yum install percona-server-server


Percona Server for MySQL 8.0 also provides the TokuDB storage engine and MyRocks storage engines which can be installed as plugins. For more information on how to install and enable the TokuDB storage review the TokuDB Installation document. For information on how to install and enable MyRocks review the section Percona MyRocks Installation Guide.

Percona yum Testing repository

Percona offers pre-release builds from our testing repository. To subscribe to the testing repository, you’ll need to enable the testing repository in /etc/yum.repos.d/percona-release.repo. To do so, set both percona-testing-$basearch and percona-testing-noarch to enabled = 1 (Note that there are three sections in this file: release, testing and experimental - in this case it is the second section that requires updating). NOTE: You’ll need to install the Percona repository first (ref above) if this hasn’t been done already.

Installing Percona Server for MySQL using downloaded rpm packages

  1. Download the packages of the desired series for your architecture from the download page. The easiest way is to download bundle which contains all the packages. Following example will download Percona Server for MySQL 8.0.21-12 release packages for CentOS 8:

    $ wget
  2. Unpack the bundle to get the packages: tar xvf Percona-Server-8.0.21-12-r7ddfdfe-el8-x86_64-bundle.tar

  3. To view a list of packages, run the following command:

    $ ls *.rpm
    percona- server-shared-8.0.21-12.2.el8.x86_64.rpm
  4. Install jemalloc with the following command, if needed:

  1. For a RHEL/CentOS 8 package installation, Percona Server for MySQL requires the mysql module to be disabled before installing the packages:

    sudo yum module disable mysql
  2. Install all the packages (for debugging, testing, etc.) with the following command:

    $ sudo rpm -ivh *.rpm


When installing packages manually, you must make sure to resolve all dependencies and install any missing packages yourself.

Running Percona Server for MySQL

Percona Server for MySQL stores the data files in /var/lib/mysql/ by default. The configuration file used to manage Percona Server for MySQL is the /etc/my.cnf.

The following commands start, provide the server status, stop the server, and restart the server:

  • Percona Server for MySQL is not started automatically on RHEL and CentOS after installation. Start the server with the following command:

    $ sudo service mysql start
  • Review the service status with the following command:

    $ sudo service mysql status
  • Stop the service with the following command:

    $ sudo service mysql stop
  • Restart the service with the following command:

    $ sudo service mysql restart


RHEL 7 and CentOS 7 come with systemd as the default system and service manager so you can invoke all the above commands with sytemctl instead of service. Currently, both are supported.

Working with SELinux

For information on working with SELinux, see Working with SELinux.

Uninstalling Percona Server for MySQL

To completely uninstall Percona Server for MySQL, remove all the installed packages and data files.

  1. Stop the Percona Server for MySQL service:

    $ sudo service mysql stop
  2. Remove the packages:

    $ sudo yum remove percona-server*
  3. Remove the data and configuration files:


This step removes all the packages and deletes all the data files (databases, tables, logs, etc.). Take a backup before doing this in case you need the data.
$ rm -rf /var/lib/mysql
$ rm -f /etc/my.cnf

Contact Us

For free technical help, visit the Percona Community Forum.
To report bugs or submit feature requests, open a JIRA ticket.
For paid support and managed or professional services, contact Percona Sales.