Important: do not delete the ibdata1 file. You could destroy all your databases.
Steps:
Rename folder mysql/data -> mysql/data_old
Make a copy of mysql/backup folder and name it as mysql/data
Copy all your database folders only from mysql/data_old into mysql/data (except mysql, performance_schema, and phpmyadmin folders)
Copy mysql/data_old/ibdata1 file into mysql/data folder
Start MySQL from XAMPP control panel
It should resolve the issue.
The above is the detailed content of How to FIX: Error: MySQL shutdown unexpectedly. For more information, please follow other related articles on the PHP Chinese website!