Fix for MAMP when MySQL is not starting
I’m currently using MAMP for local PHP development on OS X. It works ok, except for a tendency to bug out when starting up again after first quitting the application once. So if you get the “Error: Could not connect to MySQL server!” notice, here’s a fix:
- Quit MAMP
- Open the terminal and type:
killall -9 mysqld - Restart MAMP
That should do it. If it’s still not working, this forum thread has more details.
15 comments so far. Go ahead, write something
You can follow any responses to this entry through the RSS feed
might have to sudo.
#1 your moms 02 May 07
Absolute life saver - thank you!
#2 Brian 12 Feb 08
Thank you so much. This saved me hours.
#3 Eli 01 Apr 08
Thank You! Saved me so much aggravation.
#4 LT 20 May 08
Tanks a lot!!!
#5 fernando 12 Aug 08
[…] If the mysql server is not working. Visit this site for a fix. […]
#6 Installing Drupal on a Mac, Problems and Process at Stetson House Web Developers Society of Philadelphia 20 Aug 08
damn straight… thanks for the posting, fixed it like a charm!
#7 soda novels 20 Aug 08
Just what I needed! Thanks a bunch for sharing this!
#8 George 05 Sep 08
No matching processes belonging to you were found
that comes up when i type it in
#9 Devan 17 Sep 08
thanks.
#10 lyonnel 27 Sep 08
Damn dude! IT worked PERFECTLY! thanks a bunch!
#11 Nick 08 Oct 08
Worked great. Danks!
#12 Sheldon 20 Oct 08
other way that might fix the same problem :
-go in the folder MAMP/db/mysql/ - delete all files that IS NOT A FOLDER (files like ‘mysql-bin.XXXXXX’ / ‘mysql-bin.index’/ ‘ibdata1’ / ‘ib_logfileX’
don’t worry, this doesn’t erase any of your database, but make sure you don’t delete the folders. That’s where the data of your databases are stored.
#13 couzinhub 11 Nov 08
Another issue that some of you might be encountering: I had MAMP working and then changed my root password. Next time I started it up, the start page kept giving me “Error: Could not connect to MySQL server!” Turns out that user ‘root’, pass ‘root’ is hard-coded into the MAMP start page at MAMP/bin/mamp/index.php. Once I changed that page to match my new pass, the start page worked.
#14 Ben 12 Nov 08
couzinhub = brilliant help. I was ready to download - reinstall. this would of caused me days of loss.
#15 jamo 13 Nov 08
Type here: