Mysql 5.7.12 Configuration

Source: Internet
Author: User

I'm going to write a blog with Express+mysql. Originally in the company's computer has been configured, but in order to facilitate at home can also be modified, so in their own computer also installed the environment.

Company computer is Win7 system 32-bit, installed is 5.5 of MySQL, with the MSI, directly click on the installation. But my own computer is the WIN10 system 64-bit, the official network only zip, only manually configured.

(Not configured do not know Ah, various problems)

Download

On the official website directly select the corresponding system is good, ready to download the time will call you to register an account, you can skip the download directly.

Extract

Find a directory and unzip the zip to the right. I put it in D: below, so now the directory is D:\mysql-5.7.12-winx64. Create a new data directory under this directory.

Setting environment variables

Right-click this computer, properties---Advanced system settings, environment variable, system variable->path variable, double-tap-new, input D:\mysql-5.7.12-winx64\bin

Using cmd

Run CMS as Administrator, switch directories to the directory where MySQL is placed, enter the bin directory

Modifying a configuration file

Copy the My-default.ini, change the name My.ini. Modify the following

Basedir = D:\mysql-5.7.12-winx64

DataDir = D:\mysql-5.7.12-winx64\data

Port = 3306

Initialization

Switch to the command line, enter mysqld–initialize carriage return

Then there will be a _ in the Flash, and then return to the No. And then I don't know if it was successful initialization is not, and entered again, the result indicates that the directory already exists.

?

Then I went to see the new data directory, there are already a lot of things.

?

The estimate should have been successful.

Then enter Mysqld–console, want to look at the status through the console, the result is not printing anything. I don't know if it was successful. Continue with the next step anyway.

?

Input Mysql–u root–p

Tips

Unable to connect. This time went to the process to see that there is a MySQL service running. Always feel wrong. Because the previous configuration, although there is a place to not understand the final reconfiguration, but the last time it was prompted to run the MySQL service, look at the process of the name should be mysqld.

?

I don't think it seems to be the install yet. So hurry install.

Okay, so this is finally starting the MySQL service.

Try again, Mysql–u root–p.

Prompt password when the direct enter, prompt password error.

?

All right, I'll just find the code. Where's the password? In a file with the suffix. Err in the data directory.

Find it, try it now ~

?

?

Finally!!! So excited. The next step is to change the randomly generated password to your own password.

?

SQL must remember the rating number Ah!! Use JS are not accustomed to forget the semicolon this thing _ (: Зゝ∠) _

?

Just check it out, it's ready, and now MySQL is installed on my computer.

Mysql 5.7.12 Configuration

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.