MySQL 5.7.14 installation configuration method graphic Tutorial (GO)

Source: Internet
Author: User
Tags mysql in

Http://www.jb51.net/article/90259.htm

********************************

Because I personally need to install MySQL in this machine, the installation process is recorded as follows, I hope to have a reference for others.

First, download the software

1. Go to MySQL website and log in to your Oracle account to download mysql-5.7.14,:http://dev.mysql.com/downloads/mysql/

2. Extract the downloaded files to the specified directory, the author extracted in C:\software\Mysql\mysql-5.7.14-winx64

Second, the installation process

1. Configure the environment variable path first, and configure the C:\software\Mysql\mysql-5.7.14-winx64\bin to its own path, which is not detailed again.

2. Copy the My-default.ini under the decompression path, and modify the name to My.ini as shown in.



3. Open the file My.ini and add the following:

?
1234 [mysqld]basedir=C:\\software\Mysql\mysql-5.7.14-winx64datadir=C:\\software\Mysql\mysql-5.7.14-winx64\dataport=3306

Where Basedir: is the above MySQL decompression path
DataDir: Subsequent initialization and other data will be saved in this directory, the file directory under the new Data folder
Port: indicates the port number of the connection database

Iii. Initializing database configuration related information
1. Run the Windows command line as an administrator
2. Go to MySQL's Unzip directory:

Reminder: You need to go to the bin directory here, otherwise there will be an error in subsequent operations.

3. Execution is initialized, and the initial password of root is generated as shown in:

Remember the initialization password that is generated at this time.

4. Follow the MySQL service. Run command: mysqld--install MySQL

Successfully installed the MySQL service.

5. At this time, you can start the MySQL service, net start MySQL
The user may receive the following error: System error 2 has occurred. The system could not find the specified file.

error Reason: as described above, when running the Install Service command: mysqld--install MySQL, we did not enter the bin directory for installation.

solution: go to the bin directory, first remove service, Run command mysqld--remove

Reinstall the MySQL service, run the command mysqld--install


At this point the MySQL service has been successfully started.

Iv. login database, change password
Command line Input mysql-u root-p, error description: Error 1045 (28000)

Workaround: Add a line in the My.ini file after [mysqld] Skip-grant-tables
At this point, turn off the MySQL service and restart.



Re-login:



No need to enter a password, enter directly.

Select MySQL Database:


Query the user table of the MySQL database, select * from user

At this point, we find that the name of the password field is authentication_string. Some may be password, whichever is the result of your enquiry.
Perform an update operation on table User: Update user set authentication_string = password ("*******") where user= "root"

The operation was successful. Quit MySQL

Remove the skip-grant-tables from the My.ini file and restart the MySQL service.



Start success. At this point, MySQL was successfully installed in Windows.

The above is the MySQL 5.7.14 installation configuration method, I hope that everyone's learning has helped.

MySQL 5.7.14 installation configuration method graphic Tutorial (GO)

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.