MySQL error 1045 (28000): Access denied for user 'root' @ 'local

Source: Internet
Author: User

Ubuntu9.10 install MySQL

Sudo apt-Get install mysql-Server

The installation is successful, and the password and OK are required at the end of the installation.

Mysql-u root-P

Enter the password.

An error occurred!
Error 1045 (28000): Access denied for user 'root' @ 'localhost' (using password: yse)

Leave the password Blank

Error 1045 (28000): Access denied for user 'root' @ 'localhost' (using password: No)

Change the password!

#/Etc/init. d/MySQL stop
# Mysqld_safe -- user = MySQL -- skip-grant-tables -- skip-Networking &
# Mysql-u root MySQL
Mysql> Update user SET Password = PASSWORD ('My password ') where user = 'root ';
Mysql> flush privileges;
Mysql> quit

#/Etc/init. d/MySQL restart
# Mysql-u root-P
Enter password:

Mysql>

Solution.

Ubuntu9.10 install MySQL

Sudo apt-Get install mysql-Server

The installation is successful, and the password and OK are required at the end of the installation.

Mysql-u root-P

Enter the password.

An error occurred!
Error 1045 (28000): Access denied for user 'root' @ 'localhost' (using password: yse)

Leave the password Blank

Error 1045 (28000): Access denied for user 'root' @ 'localhost' (using password: No)

Change the password!

#/Etc/init. d/MySQL stop
# Mysqld_safe -- user = MySQL -- skip-grant-tables -- skip-Networking &
# Mysql-u root MySQL
Mysql> Update user SET Password = PASSWORD ('My password ') where user = 'root ';
Mysql> flush privileges;
Mysql> quit

#/Etc/init. d/MySQL restart
# Mysql-u root-P
Enter password:

Mysql>

Solution.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.