1

I'm having trouble picking up from where I left off in my intro to SQL textbook which has not been opened in about 6 months. I'm receiving the message "The Mysql Server Instance has stopped" above when I try to run mysql server (system preferences/MySQL). Here is some info:

Using Max Osx 10.6 Have XAMPP up and running for separate projects (Not sure if thats relevant). I receive the following error when using the terminal:

/usr/local/mysql/bin/mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

I thought I'd find a solution here: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

But I cannot follow the question. For example, the accepted answer - I don't know if I'm connecting to local host or how to "try using "127.0.0.1" if the socket connector is not enabled/working".

I suspect that this question will lack sufficient detail for most. I'm sorry. I'm not sure why this is happening or what other info to include. I lack the knowledge which is why I'm trying to learn SQL. If there is more info that would help anyone understand whats wrong let me know.

Community
  • 1
  • 1
Doug Fir
  • 19,971
  • 47
  • 169
  • 299
  • There is a similar question answered in the below SO link http://stackoverflow.com/questions/4788381/getting-cant-connect-through-socket-tmp-mysql-when-installing-mysql-on-m – usha May 30 '13 at 15:45
  • Xampp on the Mac really puts your system through the ringer. It definitely has enough information for me to know the problem, but I've not bothered finding a solution: I just pointed to a different MySQL instance on my network. – cwallenpoole May 30 '13 at 15:50
  • @Vimsha Thanks for the comment. I looked at that question but there are 12 answers and I'm not sure which one to go with. I can eliminate some of them, I think, by stating that SQL Server is not running. This surely would exclude the accepted answer? – Doug Fir May 30 '13 at 15:53
  • Instead of XAMPP you might want to try [Homebrew](http://mxcl.github.io/homebrew/) which is a more native package management platform. – tadman May 30 '13 at 16:54
  • @tadman OK but I don't understand how that helps me in this instance. My immediate goal is to get SQL Server running – Doug Fir May 30 '13 at 17:38
  • I know for a fact that the Homebrew MySQL install works. The XAMPP one is more flaky. Your call. – tadman May 30 '13 at 23:11

2 Answers2

0

I left the problem and came back to it later with a restarted computer. My problem appears to be that I already had SQL Server running locally via phpMyAdmin. I was not aware that one cannot run more than one instance of SQL. I was trying to access SQL via the terminal in order to follow along with text book exercises.

So when I close the locally hosted phpMyAdmin, I am then able to start mySQL server via the terminal.

This must sound ridiculous to the folk on here. Thanks for the answers nonetheless and I hope that this answer helps a future dope like me down the line.

Doug Fir
  • 19,971
  • 47
  • 169
  • 299
0

This is for future reference for people looking up the problem (Ie, it is not really applicable to this guys situation, but might really help someone else out, when they look for the error on Google): I had the same issue for a while and the problem is probably related to improper installation. The trick is to be patient (and for those that are not experts at computers, it is not the usual installation as a normal user friendly downloading process). I strongly suggest anyone that has been going through this problem to:

  1. Uninstall the application.
  2. Reinstall it following this guys steps: https://www.youtube.com/watch?v=ecIrbPwNPBM

Some pointers while watching what he does:

  • Around 2:36, PaTH is incorrect, it should be PATH.
  • After editing the bashrc file, exit the terminal in order for the mysql command to work

Hope this helps :)

Sixter
  • 11
  • 2