Installing Percona XtraBackup on Debian and Ubuntu

Ready-to-use packages are available from the Percona XtraBackup software repositories and the download page.

Supported Releases:

  • Debian:
  • 6.0 (squeeze)
  • 7.0 (wheezy)
  • 8.0 (jessie)
  • Ubuntu:
  • 12.04LTS (precise)
  • 14.04LTS (trusty)
  • 14.10 (utopic)
  • 15.04 (vivid)

Supported Platforms:

  • x86
  • x86_64 (also known as amd64)

What’s in each DEB package?

The percona-xtrabackup package contains the latest Percona XtraBackup GA binaries and associated files.

The percona-xtrabackup-dbg package contains the debug symbols for binaries in percona-xtrabackup.

The percona-xtrabackup-test package contains the test suite for Percona XtraBackup.

The percona-xtrabackup-2x package contains the older version of the Percona XtraBackup.

Installing Percona XtraBackup from Percona apt repository

  1. Import the public key for the package management system

    Debian and Ubuntu packages from Percona are signed with the Percona’s GPG key. Before using the repository, you should add the key to apt. To do that, run the following commands as root or with sudo:

    $ sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A


    In case you’re getting timeouts when using keys.gnupg.net as an alternative you can fetch the key from keyserver.ubuntu.com.

  2. Create the apt source list for Percona’s repository:

    You can create the source list and add the Percona repository by running:

    $ echo "deb http://repo.percona.com/apt "$(lsb_release -sc)" main" | sudo tee /etc/apt/sources.list.d/percona.list

    Additionally you can enable the source package repository by running:

    $ echo "deb-src http://repo.percona.com/apt "$(lsb_release -sc)" main" | sudo tee -a /etc/apt/sources.list.d/percona.list
  3. Remember to update the local cache:

    $ sudo apt-get update
  4. After that you can install the package:

    $ sudo apt-get install percona-xtrabackup-22

Percona apt Testing repository

Percona offers pre-release builds from the testing repository. To enable it add the just add the testing word at the end of the Percona repository definition in your repository file (default /etc/apt/sources.list.d/percona.list). It should looks like this (in this example VERSION is the name of your distribution):

deb http://repo.percona.com/apt VERSION main testing
deb-src http://repo.percona.com/apt VERSION main testing

Apt-Pinning the packages

In some cases you might need to “pin” the selected packages to avoid the upgrades from the distribution repositories. You’ll need to make a new file /etc/apt/preferences.d/00percona.pref and add the following lines in it:

Package: *
Pin: release o=Percona Development Team
Pin-Priority: 1001

For more information about the pinning you can check the official debian wiki.

Installing Percona XtraBackup using downloaded deb packages

Download the packages of the desired series for your architecture from the download page. Following example will download Percona XtraBackup 2.2.12 release package for Debian 8.0:

$ wget https://www.percona.com/downloads/XtraBackup/Percona-XtraBackup-2.2.12/binary/debian/jessie/x86_64/percona-xtrabackup_2.2.12-1.jessie_amd64.deb

Now you can install Percona XtraBackup by running:

$ sudo dpkg -i percona-xtrabackup_2.2.12-1.jessie_amd64.deb


When installing packages manually like this, you’ll need to make sure to resolve all the dependencies and install missing packages yourself.

Uninstalling Percona XtraBackup

To uninstall Percona XtraBackup you’ll need to remove all the installed packages.

  1. Remove the packages

    $ sudo apt-get remove percona-xtrabackup*