#2002 - The server is not responding (or the local MySQL server's socket is not correctly configured)

后端 未结 4 351
傲寒
傲寒 2021-01-03 03:40

I can\'t access to PHPMyAdmin. when i want to go there, i got this error:

#2002 - The server is not responding (or the local MySQL server\'s socket is

相关标签:
4条回答
  • 2021-01-03 04:13

    This means that mysql server is not started. This is very simply if you are using wamp left click the wampserver icon then mysql then services then install service after that restart wamp and the problem is solved

    0 讨论(0)
  • 2021-01-03 04:23

    Steps just to run the mysql server after crash.

    ** Worked on wamp server **

    1. Check the {System name}.err file inside your mysql data directory.
    2. From the log find out the databases causing issues
    3. Cut them out from the data directory (keep in some safe places).
    4. Start mysql service
    0 讨论(0)
  • 2021-01-03 04:28

    In Ubuntu, by default mysql is not listening to TCP/IP connections. It just uses a local socket.

    The current local socket is configured in /etc/mysql/my.cnf . If you open this file, you should find something similar to:

    [client]
    port            = 3306
    socket          = /var/run/mysqld/mysqld.sock
    

    What you should do is just to open PHPMyAdmin's config file (config.inc.php) and change the socket address. Maybe there's no local socket configuration on your PHPMyAdmin, or maybe it is different. This file should contain a line like (of course, adapt the address to what you found on my.cnf):

    $cfg['Servers'][$i]['socket'] = '/var/run/mysqld/mysqld.sock';
    
    0 讨论(0)
  • 2021-01-03 04:35

    go to C:\Windows\System32\drivers\etc
    edit host
    add 127.0.0.1 localhost
    and restart server refrance
    check ans

    0 讨论(0)
提交回复
热议问题