I have a complete backup of my XAMPP
installation.
Unfortunately I forgot to export my database to .sql
files. But as mentioned i have all .frm
, .idb
and ibdata1
ib_logfile*
and so on.
However if I simply copy the backed up files into the /opt/lampp/var/mysql
directory I get the following error:
(Switching back to the original directory created by the XAMPP
installation is completely fine, though.)
Connection for controluser as defined in your configuration failed.
and
phpMyAdmin tried to connect to the MySQL server, and the server
rejected the connection. You should check the host, username and
password in your configuration and make sure that they correspond to
the information given by the administrator of the MySQL server.
For my /opt/lampp/var/mysql
folder I did
sudo chown -R mysql mysql
sudo chgrp -R mysql mysql
What am I missing to restore the database from the XAMPP
backup?
Best Answer
I don't know why I didn't try this earlier, but a simple reboot resolved this issue. Note, that the simple restart of xampp and thus of mysql and apache did not work.