When I open XAMPP and click start MySQL button and it gives me an error. I had started it just before, but now it isn\'t working.
12:19:12 PM [mysql]
No solution above worked for me. then I did below:
I deleted all the files inside C:\xampp\mysql\data\ directory except folders in this directory. It worked perfectly fine but my previous databases are not working now. So do above if you don't care it will delete all your previous databases in phpmyadmin.
if you are using MariaDB you can try this:
xampp/mysql/backup
files into xampp/mysql/data
XAMPP
as Administrator
(make sure mysql is installed you can see a green tick if is installed)
Hope it helps!
Make sure the system time is correct. Mine was set to the year 2040 somehow, correcting the date solved the problem.
in my case i did following steps and it worked:
In Xampp control panel click on "Services" button from the right side toolbar
Then find "MySQL" from the services List
Click on it and from the left side of the panel click on "stop"
Turn back in Xampp control panel and click on start.
i was facing the same issue and none of the solutions stated above helped me. i went to the mysql configuration file (my.ini) and changed the port number under [mysqld].By default mysql runs on 3306 port.
port= 3306
i changed it to ,
port= 8111
Then run as Administrator.Finally this worked for me.