0

Cannot access phpmyadmin. Everytime I enter the username and password the given error is shown...

2002 - Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

The server is not responding (or the local server's socket is not correctly configured).

1
  • I added an image to show there was no mysqld in /usr/bin
    – yorroy
    May 19 '15 at 19:05
2

I had this error and it caused me a lot of headaches! However, I found that restarting SQL fixed it for me. I had to try restarting a couple of times but it did eventually work. I used the Stop command followed by the Start command.

The commands you want are:

Start:

sudo /etc/init.d/mysql start

Stop:

sudo /etc/init.d/mysql stop

Restart / reload configs:

sudo /etc/init.d/mysql restart

These were taken from:

https://superuser.com/questions/282115/how-to-restart-mysql

0

Try walking through the set up steps for the pset again. You may not have correctly configured the permissions. Did you get any errors when trying to modify the host file as specified in the pset instructions below?

sudo gedit /etc/hosts in order to run gedit as the appliance’s "superuser" (aka "root") so that you can edit what’s otherwise a read-only file. Carefully add this line at the bottom of that file, which will associate pset7 with the appliance’s "loopback" address (which won’t ever change):

127.0.0.1 pset7 Then save the file and quit gedit.

If that fails to help, you may want to reference this thread on StackExchange.

https://stackoverflow.com/questions/4448467/cant-connect-to-local-mysql-server-through-socket-var-lib-mysql-mysql-sock

1
  • I went thru all the startup steps again. I had an experienced programmer look at my appliance and he said the problem is that mysql is not running on my appliance. He said I needed to get instructions for how to get it to run on this appliance. Can someone help with that? Or should I reinstall the appliance?
    – yorroy
    May 19 '15 at 19:03
0

enter image description hereI checked the /etc/hosts several times It has the line suggested. I've been browsing the stackexchange thread but when I do things like mysql.server start, I get mysqlserver: command not found. I've gone back and checked all the file and directory permissions. Most of the stackexchange comments I don't understand. They reference my.cnf which I can't find. enter image description here

1
  • Are you using virtualbox, VMware player, fusion? Also, have your run update50
    – lethaljd
    May 19 '15 at 19:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .