Created
February 7, 2015 18:41
-
-
Save alxsimo/abd0114c1e97fe5c3ce2 to your computer and use it in GitHub Desktop.
[MySQL] Reset MySQL root password
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
For Ubuntu Server | |
1. Set root password | |
sudo su | |
passwd | |
2. sudo /etc/init.d/mysql stop | |
3. sudo /etc/init.d/mysql start --skip-grant-tables | |
4. mysql | |
5. UPDATE mysql.user SET Password=PASSWORD('MyNewPass') WHERE User='root'; | |
6. mysql -u root -p |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment