Installing Mysql-5.7.xx-winx64.zip

Source: Internet
Author: User
Tags create directory

1 Download the MySQL Zip package to extract to a directory that needs to be installed, such as D:\Local\mysql


2 Create directory data under D:\Local\mysql


3 copy My-default.ini to My.ini, modify My.ini configuration

Basedir = D:\Local\mysql

DataDir = D:\Local\mysql\data


4 Adding environment variables

Add the D:\Local\mysql\bin to the system variable Path


5 Run cmd as Administrator

Proceed to the D:\Local\mysql\bin directory, execute the following command and wait for completion, and finally a root temporary password is displayed.

Mysqld--initialize--user=mysql--console


6 Install MySQL for system service, start MySQL

mysqld install MySQL--defaults-file= "D:\Local\mysql\my.ini"

net start MySQL


7 connecting MySQL and resetting the root password

Log in to MySQL using the temporary password above

Log in after executing what commands are reported, this is required you to change the password

ERROR 1820 (HY000): Must reset your password using ALTER USER statement before executing this statement.

Modify Password procedure

SET PASSWORD = PASSWORD (' py123456 ')

ALTER USER ' root ' @ ' localhost ' PASSWORD EXPIRE never;

Flush privileges;



Installing Mysql-5.7.xx-winx64.zip

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.