MySQL ERROR 1045 (28000): Access denied for the cause of user ' root ' @ ' localhost ' (using password:no) solution _mysql

Source: Internet
Author: User

MySQL ERROR 1045 (28000): Access denied for user ' root ' @ ' localhost ' (using password:no) solution and Reason

These two days to download the installation of MySQL5.7.11, found that the first time to use the input password, anyway, even in accordance with the online said under the mysqld add Skip-grant-tables is not, and later studied for two days, and finally find out the reasons and solutions.

Copy Code code as follows:

[MYSQLLD]
Skip-grant-tables;

Reason: Mysql 5.6 and later version out of security considerations, the root password is not empty. So in the MySQL installation process, will generate a random password as the initial password.

The password here cannot be empty, and you want to enter a randomly set password.

Password in:

D:\Program Files\mysql-5.7.11-winx64\data.

are:


This is a random password, using the root account and this random password can be logged in.

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.