无法启动phpMyAdmin.不断收到#2002套接字错误 [英] Can't start phpMyAdmin. Keep getting the #2002 socket error

查看:98
本文介绍了无法启动phpMyAdmin.不断收到#2002套接字错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近12个小时我一直在尝试设置mysql和phpMyAdmin,但没有成功.是的,经过数小时的Googleing测试,我知道这是一个普遍的问题,我已经阅读了关于stackoverflow的类似查询,但仍然无法解决该问题.....

I've been trying to set mysql and phpMyAdmin for the last 12 hours, without any success. And yes, after hours and hours of Google-ing I know that is a common problem and I've read similar queries on stackoverflow but still can't come with the solution.....

我已经尝试了一切-从更改

I've tried everything - from changing the

$cfg['Servers'][$i]['port']

文件中的

3306127.0.0.1 ....

config.inc.php文件中键入套接字路径-tmp/mysql.php/var/mysql/mysql.sock.

typing the socket path in the config.inc.php file - both tmp/mysql.php and the /var/mysql/mysql.sock.

我尝试更改my.cnf文件和php.ini中的套接字路径....但我不断遇到相同的错误:

I've tried changing the socket path in the my.cnf file and the php.ini....but I keep getting the same error:

#2002 - No such file or directory
The server is not responding (or the local server's socket is not correctly configured).

我正在使用MySQL(5.1.65),PhpMyAdmin(3.5.2.2)和PHP(5.3.8).

I'm using MySQL (5.1.65), PhpMyAdmin (3.5.2.2) and PHP (5.3.8).

推荐答案

我最近也在Mac OS Sierra上也遇到了此问题. Apache服务器正常工作,但mysql无法正常工作.在寻找解决方案之后,阅读了大量的帖子,我找到了这个解决方案.而且有效!

I have recently encountered this problem on Mac OS Sierra too. Apache server is working but mysql is not. After searching for a solution, reading lots of posts I found this solution. And it worked!

解决方案是导航到mysql文件夹,在我的情况下为

The solution is to navigate to the mysql folder, in my case its,

/Applications/MAMP/db/mysql56/

并删除除文件夹以外的所有文件.然后再次重新启动MAMP.

and remove all the files except folders. Then restart MAMP again.

这篇关于无法启动phpMyAdmin.不断收到#2002套接字错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆