XAMPP – MySQL shutdown unexpectedly
The Xampp control panel says MySQL shutdown unexpectedly. Please help me for fix this. You can see the error below.
11:15:13 PM [mysql] Attempting to start MySQL app... 11:15:13 PM [mysql] Status change detected: running 11:15:14 PM [mysql] Status change detected: stopped 11:15:14 PM [mysql] Error: MySQL shutdown unexpectedly. 11:15:14 PM [mysql] This may be due to a blocked port, missing dependencies, 11:15:14 PM [mysql] improper privileges, a crash, or a shutdown by another method 11:15:14 PM [mysql] Press the Logs button to view error logs and check 11:15:14 PM [mysql] the Windows Event Viewer for more clues 11:15:14 PM [mysql] If you need more help, copy and post this 11:15:14 PM [mysql] entire log window on the forums
Follow these steps, In your Xampp installed location,
- Stop MySQL from XAMPP control panel.
- Go to the mysql installation location.
- Rename the folder mysql/data to mysql/data_old (you can use any name)
- Create a new folder mysql/data
- Copy the content that resides in mysql/backup to the new mysql/data folder
- Copy all your database folders that are in mysql/data_old to mysql/data (skipping the mysql, performance_schema, and phpmyadmin folders from data_old)
- Finally copy the ibdata1file from mysql/data_old and replace it inside mysql/data folder
- Start MySQL from XAMPP control panel