当前位置:网站首页>MySQL forgot password
MySQL forgot password
2022-07-31 04:52:00 【geejkse_seff】
mysql forgetting password is a common thing, so how to solve it?
1. First shut down the MySQL service, two methods:
(1) Open the command line cmd and enter the net stop mysql command to close the MySQL service.
(2) Find the service, find MYSQL56 (my computer is installed with mysql5.6, so here is MYSQL56) and then close
2. Open the MySQL installation path and enter the bin directory. There are two methods:
(1) Enter cmd in the directory to get the command line window, and the directory where it is located is also in the bin directory
(2) Or open the command line, enter cd F:mysqlin and press Enter
3. Remove the authentication check
mysqld --skip-grant-tablesIn the cmd window of the previous step, enter mysqld --skip-grant-tables and press Enter
This command is to remove the authentication check.Prepare for the following operation, do not close!!!
4, enter the mysql container
Open a new command line, enter mysql and press Enter
mysql
5. Verify that the database login is successful
show databases;
The database indicates successful login.
6. Input Use mysql database.
use mysql;The mysql database stores usernames and passwords.
7. View all tables
show tables;The user table stores account information such as username, password, permissions, etc.
8. View account information
select user,host,password from user;
9. Change the root password, the password is 123456
update user set password=password('123456') where user='root' and host='localhost';
10. Check account information again
select user,host,password from user;You can see that the password has been changed.
11. Verify the database in Navicat.

This will solve the problem of forgetting the database password~~~
Let me introduce myself first. The editor graduated from Shanghai Jiaotong University in 2013. I worked in a small company and went to big factories such as Huawei and OPPO. I joined Alibaba in 2018, until now.I know that most junior and intermediate java engineers want to upgrade their skills, they often need to explore their own growth or sign up to study, but for training institutions, the tuition fee is nearly 10,000 yuan, which is really stressful.Self-learning that is not systematic is very inefficient and lengthy, and it is easy to hit the ceiling and the technology stops.Therefore, I collected a "full set of learning materials for java development" for everyone. The original intention is also very simple. I hope to help friends who want to learn by themselves but don't know where to start, and at the same time reduce everyone's burden.Add the business card below to get a full set of learning materials
边栏推荐
- Lua,ILRuntime, HybridCLR(wolong)/huatuo hot update comparative analysis
- input输入框展示两位小数之precision
- Gaussian distribution and its maximum likelihood estimation
- Three oj questions on leetcode
- 两个地址池r2负责管地址池r1负责管dhcp中继
- Error EPERM operation not permitted, mkdir ‘Dsoftwarenodejsnode_cache_cacach两种解决办法
- Doris学习笔记之监控
- WPF WPF 】 【 the depth resolution of the template
- PWN ROP
- .NET-6.WinForm2.NanUI学习和总结
猜你喜欢

数字经济时代的开源数据库创新 | 2022开放原子全球开源峰会数据库分论坛圆满召开

产学研用 共建开源人才生态 | 2022开放原子全球开源峰会教育分论坛圆满召开

View source and switch mirrors in two ways: npm and nrm

专访 | 阿里巴巴首席技术官程立:云+开源共同形成数字世界的可信基础

MySQL optimization: from ten seconds to three hundred milliseconds

Puzzle Game Level Design: Reverse Method--Explaining Puzzle Game Level Design

SOLVED: After accidentally uninstalling pip (two ways to manually install pip)

EasyExcel的简单读取操作

【C语言】操作符详解

The third is the code to achieve
随机推荐
ERP生产作业控制 金蝶
SOLVED: After accidentally uninstalling pip (two ways to manually install pip)
ERROR 1064 (42000) You have an error in your SQL syntax; check the manual that corresponds to your
DVWA安装教程(懂你的不懂·详细)
VScode+ESP32 quickly install ESP-IDF plugin
C语言表白代码?
The idea project obviously has dependencies, but the file is not displayed, Cannot resolve symbol 'XXX'
ERROR 2003 (HY000) Can‘t connect to MySQL server on ‘localhost3306‘ (10061)解决办法
1. 获取数据-requests.get()
MySQL忘记密码怎么办
The 15th day of the special assault version of the sword offer
专访 | 阿里巴巴首席技术官程立:云+开源共同形成数字世界的可信基础
Hand in hand to realize the picture preview plug-in (3)
三道leetcode上的oj题
重磅 | 开放原子校源行活动正式启动
mysql使用on duplicate key update批量更新数据
CentOS7 安装MySQL 图文详细教程
unity2d小游戏
MySQL数据库必会的增删查改操作(CRUD)
PWN ROP