Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XAMPP - Error: MySQL shutdown unexpectedly

Tags:

I have reinstalled XAMPP for some reason and MySQL is not working, giving the following error in the console:

01:56:03  [mysql]   Error: MySQL shutdown unexpectedly. 01:56:03  [mysql]   This may be due to a blocked port, missing dependencies,  01:56:03  [mysql]   improper privileges, a crash, or a shutdown by another method. 01:56:03  [mysql]   Check the "/xampp/mysql/data/mysql_error.log" file 01:56:03  [mysql]   and the Windows Event Viewer for more clues 

When checking the "/xampp/mysql/data/mysql_error.log" file I get:

130302  1:48:06  InnoDB: Waiting for the background threads to start 130302  1:48:07 InnoDB: 1.1.8 started; log sequence number 1600324627 130302  1:48:07 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306 130302  1:48:07 [Note]   - '0.0.0.0' resolves to '0.0.0.0'; 130302  1:48:07 [Note] Server socket created on IP: '0.0.0.0'. 130302  1:51:12 [Note] Plugin 'FEDERATED' is disabled. 130302  1:51:12 InnoDB: The InnoDB memory heap is disabled 130302  1:51:12 InnoDB: Mutexes and rw_locks use Windows interlocked functions 130302  1:51:12 InnoDB: Compressed tables use zlib 1.2.3 130302  1:51:12 InnoDB: Initializing buffer pool, size = 16.0M 130302  1:51:12 InnoDB: Completed initialization of buffer pool 130302  1:51:12 InnoDB: highest supported file format is Barracuda. InnoDB: The log sequence number in ibdata files does not match InnoDB: the log sequence number in the ib_logfiles! 130302  1:51:12  InnoDB: Database was not shut down normally! InnoDB: Starting crash recovery. InnoDB: Reading tablespace information from the .ibd files... InnoDB: Restoring possible half-written data pages from the doublewrite InnoDB: buffer... 130302  1:51:13  InnoDB: Waiting for the background threads to start 130302  1:51:14 InnoDB: 1.1.8 started; log sequence number 1600324627 130302  1:51:14 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306 130302  1:51:14 [Note]   - '0.0.0.0' resolves to '0.0.0.0'; 130302  1:51:14 [Note] Server socket created on IP: '0.0.0.0'. 130302  1:56:01 [Note] Plugin 'FEDERATED' is disabled. 130302  1:56:01 InnoDB: The InnoDB memory heap is disabled 130302  1:56:01 InnoDB: Mutexes and rw_locks use Windows interlocked functions 130302  1:56:01 InnoDB: Compressed tables use zlib 1.2.3 130302  1:56:01 InnoDB: Initializing buffer pool, size = 16.0M 130302  1:56:01 InnoDB: Completed initialization of buffer pool 130302  1:56:01 InnoDB: highest supported file format is Barracuda. InnoDB: The log sequence number in ibdata files does not match InnoDB: the log sequence number in the ib_logfiles! 130302  1:56:01  InnoDB: Database was not shut down normally! InnoDB: Starting crash recovery. InnoDB: Reading tablespace information from the .ibd files... InnoDB: Restoring possible half-written data pages from the doublewrite InnoDB: buffer... 130302  1:56:02  InnoDB: Waiting for the background threads to start 130302  1:56:03 InnoDB: 1.1.8 started; log sequence number 1600324627 130302  1:56:03 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306 130302  1:56:03 [Note]   - '0.0.0.0' resolves to '0.0.0.0'; 130302  1:56:03 [Note] Server socket created on IP: '0.0.0.0'. 

That is just a part of the log, the full one is a bit too big.

Help?

like image 750
cgf Avatar asked Mar 02 '13 02:03

cgf


People also ask

Why is MySQL shutdown unexpectedly?

In some cases, the problem appears after users reinstall XAMPP on their computer. The reason this happens is when the MySQL files are corrupted or damaged in which case you will have to use the backup folder that can be found in the mysql directory.


1 Answers

Make sure you backup the mentioned folders before taking any action!

This worked for me,

  1. Quit the XAMPP
  2. Cut all files in C:\xampp\mysql\backup
  3. Paste and replace files into C:\xampp\mysql\data
  4. Run the XAMPP as administrator
like image 177
letmecheck Avatar answered Oct 12 '22 23:10

letmecheck