错误号2003.无法连接到mysql服务器 [英] Error No. 2003. Can't connect to mysql server

查看:569
本文介绍了错误号2003.无法连接到mysql服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我花了两天时间搜索和探索有关错误2003的解决方案. 无法在服务器名称"上连接到mysql服务器.

I has had two days searching and exploring solutions regarding the error 2003. Can't connect to mysql server on 'Server name'.

防火墙关闭,我添加了端口3306,这是mysql使用的端口.

The firewall is off and I had added the port 3306, the one that mysql uses.

有什么建议吗?

推荐答案

请参阅以下常见问题解答,其中描述了如何解决此问题:

Please refer this FAQ which describes how to solve this issue: http://faq.webyog.com/content/23/15/en/error-no-2003-can_t-connect.html

错误号2003:无法连接到本地主机"(或其他主机)上的MySQL服务器

Error No. 2003: Can't connect to MySQL server on 'localhost' (or some other host)

仅仅意味着由于以下(或类似原因)之一而无法进行连接:

simply means that connection is not possible for one of the following (or similar) reasons:

  • 在指定主机上没有运行MySQL服务器

  • There is no MySQL server running at the specified host

不允许使用TCP-IP连接到MySQL服务器.检查MySQL配置文件中的跳过网络"设置(在Windows上为my.ini,在Unix/Linux上为my.cnf).应该像#skip-networking"一样被注释掉.如果未将其注释掉,请执行该操作,然后重新启动MySQL服务器,以使更改生效. SQLyog需要使用TCP-IP进行连接.

Connection to the MySQL server is not allowed using TCP-IP. Check the 'skip-networking' setting in the MySQL configuration file (my.ini on Windows, my.cnf on Unix/Linux). It shall be commented out like '#skip-networking'. If it is not commented out, then do it and restart the MySQL server for the change to take effect. SQLyog needs to connect using TCP-IP.

某些网络问题阻止了连接.可能是网络配置错误或防火墙问题.

Some networking issue prevents connection. It could be a network malconfiguration or a firewall issue.

当尝试通过ISP连接到MySQL服务器时,此错误消息通常表示与MySQL的直接连接已被阻止.然后,您必须使用HTTP隧道或SSH隧道进行连接.

When trying to connect to a MySQL server at an ISP this error message often indicates that direct connection to MySQL has been blocked. You must then use HTTP-tunneling or SSH-tunneling to connect.

这篇关于错误号2003.无法连接到mysql服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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