1.查看配置文件:
skip-networking #注释掉 因为它是屏蔽掉一切TCP/IP连接
bind-address = 127.0.0.1 #它和上一个选项是异曲同工,要想远程连接,也得注释掉
2.如果以上工作都做过还是出现:
ERROR 2003 (HY000): Can't connect to MySQL server on '*.*.*.*' (113),那就得考虑防火墙的问题了,关掉防火墙/etc/rc.d/init.d/iptables stop
修改完后需要 restart mysql (/etc/init.d/mysql restart)
相关文章
- mysql命令运行报错:Can‘t connect to local MySQL server through socket ‘/var/run/mysqld/‘
- MySQL 连接错误Can‘t connect to MySQL server on (61)
- can‘t connect to MySQL server on ip(10060)的解决方案
- SELinux导致PHP连接MySQL异常Can't connect to MySQL server的解决方法
- ERROR 2002 (HY000): Cant connect to local MySQL server through socket的解决方法
- The server quit without updating PID file (/var/lib/mysql/)的解决办法
- MySQL:提示:The server quit without updating PID file问题的解决办法
- 23. Can't connect to X11 window server using '127.0.0.1:0.0' as the value of the DISPLAY variable.解决办法
- mysql遇到的问题:can't creat/write to file "/var/mysql/xxxx.MYI"
- 【mysql报错】ERROR 2002 (HY000): Can‘t connect to local MySQL server through socket ‘/tmp/‘