mysql解压版Can't connect to MySQL server on 'localhost' (10061)解决方法
https://www.cnblogs.com/txwtech/p/14751496.html
D:\mysql-5.7.24-winx64\bin>mysql -uroot -p55667788
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)
1.可能服务没有开启或者安装
可以使用, mysqld --install mysql,安装后,可以win+r, services.msc,查看,是否有mysql的服务,可以直接点击启动。
然后也可以cmd启动:net start mysql,
2. my.ini文件更改了端口:默认3306.
如果改成其它的端口。则如下方法:-P3307,指定登录的端口
D:\mysql-5.7.24-winx64\bin>mysql -uroot -P3307 -p55667788
D:\mysql-5.7.24-winx64\bin>mysql -uroot -P3307 -p55667788 mysql: [Warning] Using a password on the command line interface can be insecure. Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3 Server version: 5.7.24 MySQL Community Server (GPL) Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql>
欢迎讨论,相互学习。
cdtxw@foxmail.com