OR if at first you don’t succeed, search and search again?
What started as a simple task chewed up a good hour of time today… Eager to start dabbling in Drupal, I decided to get the needed parts running locally on my MacBookPro. I got MySQL 5.x downloaded and installed. I mucked up my root passwords (typo) and spent 12 minutes in vain for the right way to reset it…. upscrolling my terminal window revealed the goof in my earlier set up of the root password (yup some of the time sink is my own fault).
Next I got a copy of phpMyAdmin, to run locally to do basic database admin. It should be a pretty basic set up since it is behind my firewall, so my security can be, well, lax. Yikes. I keep getting all kinds of errors:
MySQL said:#2002 – The server is not responding (or the local MySQL server’s socket is not correctly configured)
which stumped me since I was connecting fine on the command line. And the socket file is where it is supposed to be.
So I googled the entire error message and got reams of hits, mostly people in forums asking for help. The first 5 guess attempts I followed were dead ends. Finally I got the right answer buried at Nick’s Tech Blog:
If you are running MySQL and phpMyAdmin on Mac OS X, and you just upgraded to OS X 10.4.4, you may have seen this error message when trying to access your MySQL server using phpMyAdmin: “The server is not responding (or the local MySQL server’s socket is not correctly configured)”. If this has happened to you, here is the fix:
1. load /private/etc/php.ini into your favorite editor. You may have to become root and change permissions on the file in order to edit it.
2. find the line that says ‘mysql.default_socket = ‘.
3. change that line to say ‘mysql.default_socket = “/tmp/mysql.sock”‘, and save php.ini.
4. as root, on the command line in a terminal window, restart the Apache webserver by typing ‘apachectl graceful’.
BINGO! Bling! That was it.
That is pretty obscure indeed. Thank you Google, thank you Nick.
The post "Googling the Obscure Technical Answer" was originally cracked open and scrambled from a rotten egg at CogDogBlog (http://cogdogblog.com/2006/05/googling-the-obscure-technical-answer/) on May 17, 2006.