当前位置:网站首页>【踩坑系列】mysql 修改root密码失败
【踩坑系列】mysql 修改root密码失败
2022-07-03 07:36:00 【涛涛之海】
【踩坑系列】 mysql 修改root密码失败
问题原因
mysql 修改root密码失败 ,主要是因为root的host不是localhost,是%的问题。
修改密码的步骤

-- 切换到 mysql bin 路径
--先登录mysql
mysql -u root -p
--输入密码
-- 切换到mysql数据
use mysql;
-- 查询用户信息
select user,host from user;
+------------------+-----------+
| user | host |
+------------------+-----------+
| root | % |
| admin | localhost |
| mysql.infoschema | localhost |
| mysql.session | localhost |
| mysql.sys | localhost |
| zhangj | localhost |
+------------------+-----------+
注意我的root,host是’%’
ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY '123';
边栏推荐
- Paper learning -- Study on the similarity of water level time series of Xingzi station in Poyang Lake
- 项目经验分享:基于昇思MindSpore,使用DFCNN和CTC损失函数的声学模型实现
- Project experience sharing: realize an IR Fusion optimization pass of Shengsi mindspire layer
- Industrial resilience
- 項目經驗分享:實現一個昇思MindSpore 圖層 IR 融合優化 pass
- Web router of vertx
- 【MindSpore论文精讲】AAAI长尾问题中训练技巧的总结
- Sent by mqtt client server of vertx
- Analysis of the problems of the 7th Blue Bridge Cup single chip microcomputer provincial competition
- Lucene hnsw merge optimization
猜你喜欢

Analysis of the problems of the 7th Blue Bridge Cup single chip microcomputer provincial competition

Go language foundation ----- 03 ----- process control, function, value transfer, reference transfer, defer function

IO stream system and FileReader, filewriter

技术干货|百行代码写BERT,昇思MindSpore能力大赏

不出网上线CS的各种姿势

【MySQL 11】怎么解决MySQL 8.0.18 大小写敏感问题

Leetcode 213: looting II

VMWare网络模式-桥接,Host-Only,NAT网络

技术干货|昇思MindSpore NLP模型迁移之LUKE模型——阅读理解任务

Collector in ES (percentile / base)
随机推荐
VMWare网络模式-桥接,Host-Only,NAT网络
Technology dry goods | luxe model for the migration of mindspore NLP model -- reading comprehension task
Technical dry goods Shengsi mindspire lite1.5 feature release, bringing a new end-to-end AI experience
为什么说数据服务化是下一代数据中台的方向?
Unified handling and interception of exception exceptions of vertx
Pgadmin 4 v6.11 release, PostgreSQL open source graphical management tool
Go language foundation ----- 15 ----- reflection
项目经验分享:基于昇思MindSpore,使用DFCNN和CTC损失函数的声学模型实现
不出网上线CS的各种姿势
Vertx's responsive MySQL template
Hnsw introduction and some reference articles in lucene9
Go language foundation ----- 13 ----- file
Technical dry goods | hundred lines of code to write Bert, Shengsi mindspire ability reward
Go language foundation ----- 10 ----- string related operations (operation function, string conversion)
Vertx restful style web router
Introduction of buffer flow
截图工具Snipaste
Project experience sharing: realize an IR Fusion optimization pass of Shengsi mindspire layer
Image recognition and detection -- Notes
Some experiences of Arduino soft serial port communication