MySQL restore through the command line

  1. Start your terminal emulator and move to the Backup Manager installation directory.

    cd /opt/MXB/bin

  2. Initiate the recovery of your MySQL server.

    ./ClientTool control.restore.start -datasource MySql -selection mysqldb

    Here are some options:

    • You can restore to the current directory (in-place restore) under certain circumstances. To perform a restore to an intermediate directory, specify the -restore-to parameter, for example -restore-to /tmp.
    • You can specify the backup session that you want to restore (by default the most recent session is selected). This is done using the -time parameter – for example -time "2016-09-02 14:44:39".

    You can check the current status of the restore session using the control.session.list command.

  3. (if applicable)

    If you recovered MySQL to an intermediate directory, you will need to copy the recovered files to the appropriate data directory for the recovered instance.

    For example, on Linux


    For example, on Windows

    C:\ProgramData\MySQL\MySQL Server 5.5\data

  4. (if applicable)

    On Linux, original file locations and permissions cannot be determined, because Percona XtraBackup files are used and these do not contain the original file locations and permissions.

    For example:

    chown -R mysql:mysql /var/lib/mysql

  5. Restart the MySQL service to apply the changes.


To get details on a particular command (output structure, required arguments and optional arguments), enter the following string to your terminal emulator:

./ClientTool help -c <command>