简体   繁体   中英

Why won't MySQL start on my XAMPP install?

I've been running without any problem Wordpress locally on my W10 x64 PC for over a week. I turned on my computer this morning, opened XAMPP 3.2.4 and I am unable to start the MySQL module. "Error: MySQL shutdown unexpectedly." At first it says:

16:25:35 [mysql] Attempting to start MySQL service... 16:25:35 [mysql] Status change detected: running

And then this:

16:25:43 [mysql] Error: MySQL shutdown unexpectedly.

I tried changing port, reinstalling services, removing some files in the MySQL data folder (trying to follow the online guides about problems similar to mine) but nothing worked. When I manually try to start the MySQL service I get the error 1067.

I uploaded the error log file here: https://drive.google.com/file/d/1q-wQm5a5uChF6_6UCsfVEBFoeSvKwh2E/view?usp=sharing

It seems that you have your first warning at: 2019-11-13 14:00:05 6 [Warning] Failed to load slave replication state from table mysql.gtid_slave_pos: 1932: Table 'mysql.gtid_slave_pos' doesn't exist in engine

Do you have a replication schema woriking? if not, you can rename master.info files to avoid replication.

Besides that you have your first error related to files access: 2019-11-13 14:10:32 0 [ERROR] InnoDB: Cannot open datafile for read-only: '.\virtualnordicdb\wp_commentmeta.ibd' OS error: 203

Can you access that file and the file has correct the write/read privileges

And Finally you have space enough in your hard drive? 019-11-13 14:20:25 0 [Note] mysqld.exe: Aria engine: starting recovery recovered pages: 0% 10%191113 14:20:26 [ERROR] mysqld got exception 0xc0000005;

I was able to fix this by unistalling and reinstalling XAMPP. I then copied the website folder back in htdocs, and finally went to "mysql>data", copied the database folder of the website and pasted the "ibdata1" file that I had before reinstalling XAMPP.

I came up with this solution thanks to this answer on another post: https://stackoverflow.com/a/50855748/12367579

I have been to this problem thousands of times. This problem is related to some custom things such as other programs or duplication.

I can give you several solutions:

  1. Check Control Panel

    Maybe you have installed your Xampp several times. Go there and check on the bottom. If there are too many Xampp installs, uninstall them all. Don't forget to save your xampp folder with htdocs and mysql.

  2. Check your programs installed on pc

    There are too many suspicious programs like Teamviewer or VMWare that block the port of mysql. Try to uninstall it, and install them again after finishing work with your Xampp.

  3. Changing the port

    Go to XAMPP Control Panel and near to MYSQL go to Config > my.ini Search for port=3306 , and replace all occurrences' values with 3336 . After that, go to CONFIG at the top on the right, then to Service and Port Settings , after it at MYSQL tab. On that tab change the value of port to 3336 . After that click save and then quit your XAMPP.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM