Forum Thread: MySQL Not Working

when i try to run mysql through the bash shell by typing "mysql" it will give me the following " Can't connect to local mysql server through socket '/var/run/mysqld/mysqld.sock' (2) "

I'm running kali, and have tried on root to see if it would make a difference but did not. Also when i try going to /var/run/mysqld/mysqld.sock it says no such file or directory

5 Responses

/sbin/service mysqld start

Should be the right command off the top of my head, someone please correct me if I'm wrong.

Basically if you have an issue where you can't connect; check and make sure it's on before you run down the list of potential problems. That's just basic I.T. problem solving.

ghost_

Sorry guys, i was trying to start it under a different account other than root. I did not give my other users permision to use MySQL.

When I started mysql from an account other than root from the GUI it would give me sh: 1: service: not found. Which made me believe it was something to do other than permisions.

Share Your Thoughts

  • Hot
  • Active