2. Installation from Packages

2.1. RHEL/CentOS

Percona TokuMX is available for CentOS 5, 6 and 7.

The packages come in three components:

  • tokumx-enterprise contains the mongo client shell and various tools like mongoimport and mongoexport.
  • tokumx-enterprise-common contains the Fractal Tree indexing libraries and some documentation.
  • tokumx-enterprise-server contains the mongod database server and the mongos routing server.

Important

Before starting, make sure you have read about Replacing MongoDB and Migrating to TokuMX. You may want to export your existing data out of basic MongoDB before installing Percona TokuMX.

  1. Install the Percona repository

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

    yum install http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm
    

    You should see some output such as the following:

    Retrieving http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm
    Preparing...                ########################################### [100%]
       1:percona-release        ########################################### [100%]
    

Note

RHEL/Centos 5 doesn’t support installing the packages directly from the remote location so you’ll need to download the package first and install it manually with rpm:

wget http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm
rpm -ivH percona-release-0.1-3.noarch.rpm
  1. Testing the repository

    Make sure packages are now available from the repository, by executing the following command:

    yum list | grep tokumx
    

You should see output similar to the following:

...
libtokumx-enterprise.x86_64                 2.0.2-1.el6                  percona-release-x86_64
libtokumx-enterprise-devel.x86_64           2.0.2-1.el6                  percona-release-x86_64
tokumx-enterprise.x86_64                    2.0.2-1.el6                  percona-release-x86_64
tokumx-enterprise-common.x86_64             2.0.2-1.el6                  percona-release-x86_64
tokumx-enterprise-debuginfo.x86_64          2.0.2-1.el6                  percona-release-x86_64
tokumx-enterprise-server.x86_64             2.0.2-1.el6                  percona-release-x86_64
...
  1. Install the packages

    You can now install Percona TokuMX by running:

    yum install tokumx-enterprise
    

Tip

After installing, read the instructions for Upgrading TokuMX.

Note

To control the mongod data server, use service:

$ sudo service tokumx start
$ sudo service tokumx restart
$ sudo service tokumx stop

Note

To enable Percona TokuMX on boot, use chkconfig:

$ sudo chkconfig tokumx on
$ sudo chkconfig tokumx off

2.2. Debian and Ubuntu

Percona TokuMX ready-to-use packages are from the Percona repositories.

Supported Releases:

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

The packages come in four components:

  • tokumx-enterprise is a metapackage that installs the full Percona TokuMX distribution.
  • tokumx-enterprise-clients contains the mongo client shell and various tools like mongoimport and mongoexport.
  • tokumx-enterprise-common contains the Fractal Tree indexing libraries and some documentation.
  • tokumx-enterprise-server contains the mongod database server and the mongos routing server.

Important

Before starting, make sure you have read about Replacing MongoDB and Migrating to TokuMX. You may want to export your existing data out of basic MongoDB before installing Percona TokuMX.

  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

Note

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

  1. 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
    
  2. Remember to update the local cache:

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

    $ sudo apt-get install tokumx-enterprise
    

Tip

After installing, read the instructions for Upgrading TokuMX.

To control the mongod data server, use service:

$ sudo service tokumx start
$ sudo service tokumx restart
$ sudo service tokumx stop

Note

Debian 8.0 (jessie) and Ubuntu 15.04 (vivid) 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.

To enable Percona TokuMX on boot, use chkconfig:

$ sudo chkconfig tokumx on
$ sudo chkconfig tokumx off