当MySQL 连接服务器时发生”Can not connect to mysql error 10061”错误时的对策
1.确认是否Mysql在安装后绑定了本地机IP127.0.0.1
打开文件 vi(vim) /etc/mysql/my.cnf
查找节点 /bind-address
如果结果:bing-address=127.0.0.1,那么就将这个ip地址改为ubuntu系统的ip地址
2.重启mysq服务
sudo /etc/init.d/mysql restart
OK,大功告成!