Subject: XtraBackup Restore Issue – Database Not Recognized but mysqldump Works
Environment:
-
Backup Server:
-
OS: Ubuntu 20.04.6 LTS
-
MySQL Version: 8.0.42
-
XtraBackup Version: 8.0.35-32
-
Datadir: /data/mysql
-
-
Restore Server:
-
OS: Ubuntu 22.04.5 LTS
-
MySQL Version: 8.0.45
-
XtraBackup Version: 8.0.35-31
-
Datadir: /media/vdata/mysql
-
Backup Command Used:
xtrabackup --backup --target-dir=/backup/Mysqlbackup --parallel=4 --user=root --password=XXXX
Restore Steps:
-
xtrabackup --prepare --target-dir=/backup/Mysqlbackup
-
systemctl stop mysql
-
rm -rf /media/vdata/mysql/*
-
xtrabackup --copy-back --target-dir=/backup/Mysqlbackup
-
chown -R mysql:mysql /media/vdata/mysql
-
rm -f /media/vdata/mysql/auto.cnf
-
systemctl start mysql
Observed Behavior:
-
Restore completes without error
-
MySQL starts successfully
-
Database folder (centraldb) exists in datadir
-
However, database is not properly recognized in some restore attempts
Validation:
-
Both source and restore servers show:
SHOW DATABASES → centraldb only -
Data consistency verified (row count matches)
-
mysqldump backup/restore works perfectly
Key Checks Already Done:
-
innodb_file_per_table = ON (both servers)
-
lower_case_table_names = 0 (both servers)
-
Datadir correctly configured
-
Backup contents verified (centraldb present)
-
Only one MySQL instance running
-
Permissions set correctly
Error Log Snippet:
-
“No existing UUID has been found… generating new UUID”
-
Server upgrade from 8.0.42 to 8.0.45 observed
-
No major InnoDB corruption errors seen
Concern:
It appears that MySQL initializes a new InnoDB dictionary (possibly due to early startup or redo log mismatch), causing XtraBackup restored data to not be properly recognized, while mysqldump works fine.
Request:
-
Guidance on ensuring proper InnoDB dictionary recognition after restore
-
Best practice to avoid UUID / initialization conflicts
-
Any known compatibility issues between MySQL 8.0.42 → 8.0.45 with XtraBackup 8.0.35
Additional Info (if needed):
Can provide full error logs, backup directory structure, and configuration files.
Thanks in advance for your support.



