Home > Database > Mysql Tutorial > Mysql-5.7.12 decompressed version installation steps tutorial

Mysql-5.7.12 decompressed version installation steps tutorial

PHPz
Release: 2017-04-02 17:57:39
Original
1491 people have browsed it

Off-topic: I haven’t installed mysql for a long time. I bought a new computer today and reinstalled it. It’s really tiring, so I wrote a tutorial to avoid forgetting it in the future.


Enter the formal tutorial below:

Step 1: Download the latest MySQL file and unzip it :
Download the latest version of MySQL–mysql-5.7.12 download
Unzip the downloaded file to your favorite location, for example, my location is D:\MySQL\mysql-5.7.12-winx64

Step 2: Configure environment variables
Not much to say here, just configure the bin directory under the path.

Step 3: Add configuration file
Directly copy the my-default.ini file under the decompression path, rename it to my.ini and edit it The content of this file is as follows:

[mysqld]basedir=D:\MySQL\mysql-5.7.12-winx64\datadir=D:\MySQL\mysql-5.7.12-winx64\data\port=3306
Copy after login

There are two main issues that need to be noted here:
1. basedir is the decompression of your mysql file above path.
2. Create a new empty folder named data under the path, which is datadir.

Step 4: Initialize the database and configure the service

Before doing this step, you must pay attention to two issues! ! ! Remember! ! !

First: Open CMD as an administrator;

Second: Use the cd command to enter the decompression path of your MySQL file!

Then executemysqld --initialize --user=mysql --console
After successful execution, after the printed text The last part is the initial password of the database. Remember to copy it, select it with the mouse, press Enter and find a place to ctrl+v.

After completing the above, open CMD as an administrator and execute
mysqld --install MySQL –>Add to System service
net start mysql –>Start mysql service

Step 5: Modify mysql Initial password
1. Open CMD and execute: mysql -u root -p
2. Enter what you just entered The initial password for the saved database.
3. Execute set password = password(‘***NewPassword***‘);

Just enter your own new password in the position of NewPassword.

This is all over, let’s start using it.

Recommended related articles:

Detailed steps to install MySQL 5.7.12 under CentOS 6.5 (pictures and text)

mysql 5.7.12 win64 Manual installation tutorial steps (pictures and text)

The above is the detailed content of Mysql-5.7.12 decompressed version installation steps tutorial. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template