← Back to team overview

maria-docs team mailing list archive

Restoring backup: instructions

 

Hello,

This page contains instructions on how to restore a backup:
https://mariadb.com/kb/en/library/full-backup-and-restore-with-mariabackup/#restoring-the-backup


1. stop MariaDB:
    # systemctl stop mariadb.service

2. datadir must be empty:
    # rm -rf /var/lib/mysql/

3. run mariabackup:
    #mariabackup --copy-back --target-dir=/var/mariadb/backup/

4. fix permissions:
    # chown -R mysql:mysql /var/lib/mysql/

5. start MariaDB:
    # systemctl start mariadb.service

mariabackup said "completed OK!" and I see that datadir contains the
restored data.

However, when following these instructions, I can't start MariaDB anymore.
I have the following error:

mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [ERROR]
Plugin 'InnoDB' init function returned error.
mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [ERROR]
Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [Note]
Plugin 'FEEDBACK' is disabled.
mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [ERROR]
Could not open mysql.plugin table. Some plugins may be not loaded
mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [ERROR]
Unknown/unsupported storage engine: InnoDB
mar 29 07:06:49 myhostname mysqld[11359]: 2019-03-29  7:06:49 0 [ERROR]
Aborting
mar 29 07:06:49 myhostname systemd[1]: mariadb.service: main process
exited, code=exited, status=1/FAILURE
mar 29 07:06:49 myhostname systemd[1]: Failed to start MariaDB 10.3.13
database server.
mar 29 07:06:49 myhostname systemd[1]: Unit mariadb.service entered failed
state.
mar 29 07:06:49 myhostname systemd[1]: mariadb.service failed.

Is there something missing in the documentation?

Thomas

Follow ups