下载wamp之后MySQL命令行打不开了怎么办!
如下图下载wamp之后打不开之前下载的mysql
Microsoft Windows [版本 10.0.19042.1165]
(c) Microsoft Corporation。保留所有权利。
C:\Users\Dell>mysql -uroot -p123456
Warning: Using a password on the command line interface can be insecure.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
C:\Users\Dell>
这里爆出1045的原因就是wamp自带的MySQL占用50端口,只需要关闭wamp的mysql端口就行了。
1.打开pc的服务
2.找到wampmysqld64右键停止服务
3.找到mysql50 的服务并启动
4.打开cmd就可以运行MySQL了
Microsoft Windows [版本 10.0.19042.1165]
(c) Microsoft Corporation。保留所有权利。
C:\Users\Dell>mysql -uroot -p123456
Warning: Using a password on the command line interface can be insecure.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
C:\Users\Dell>mysql -uroot -p123456
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 1
Server version: 5.6.48-log MySQL Community Server (GPL)
Copyright (c) 2000, 2020, 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>