Because we need to import a receipt library to the local , So I export it on the server first sql Text of , Then import it into the local , However, an error was reported when importing . Because the server uses mysql yes 8.0 Above , I guess it's because of me 5.5 Of mysql The version is a lot behind , So take advantage of this import failure problem , take mysql
change into 8.0 Of , Here are the steps
be careful
: If we want to replace it , Just like me , So the first thing is to back up the database , I'm backing it up data after , But before you put it in 8.0 Version of data There is no data in the database , So it's also being solved now , With the solution, I will update it immediately .

<> download mysql

First we need to download it mysql8.0 Version of , But the official website download is really too slow , be doomed ~ So you can find a Baidu disk when you download it

After downloading , I put it in the F:\mysql8.0.20\mysql-8.0.20-winx64

data There were no documents in the beginning , We don't have to create this ourselves

<> Configure environment variables

Environment variable found , New one

stay path Lower introduction

At this point, we have the environment variables ready

<> to configure my.ini file

We are here bin Create a my.ini file

Profile information
[mysqld] # set up 3306 port port=3306 # set up mysql The installation directory is your own
basedir=F:\mysql8.0.20\mysql-8.0.20-winx64 # set up mysql Storage directory of data in database , This is my own
datadir=F:\mysql8.0.20\mysql-8.0.20-winx64\data # Maximum number of connections allowed max_connections=200 #
Number of connection failures allowed . This is to prevent someone from trying to attack the database system from the host max_connect_errors=10 # The default character set used by the server is UTF8
character-set-server=utf8 # The default storage engine that will be used when creating new tables default-storage-engine=INNODB #
Default use “mysql_native_password” Plug in authentication #
default_authentication_plugin=mysql_native_password [mysql] # set up mysql Client default character set
default-character-set=utf8 [client] # set up mysql The default port used by the client when connecting to the server port=3306
<> install mysql

Open as Administrator cmd, Then enter mysql Of bin Under the directory , Execute the order
mysqld --initialize --console
After execution , Can print root User's initial default password , such as :
C:\Users\Administrator>cd C:\Program Files\MySQL\bin C:\Program Files\MySQL\bin
>mysqld --initialize --console 2018-04-28T15:57:17.087519Z 0 [System] [MY-013169
] [Server] C:\Program Files\MySQL\bin\mysqld.exe (mysqld 8.0.11) initializing of
serverin progress as process 4984 2018-04-28T15:57:24.859249Z 5 [Note] [MY-
010454] [Server] A temporary password is generated for root@localhost:
rI5rvf5x5G,E 2018-04-28T15:57:27.106660Z 0 [System] [MY-013170] [Server]
C:\Program Files\MySQL\bin\mysqld.exe (mysqld 8.0.11) initializing of server
has completed C:\Program Files\MySQL\bin>
among root@localhost: The following is the login password of the generated database rI5rvf5x5G,E

If we're not careful ctrl+c Copy password , But under the black window ctrl+c
Termination of proceedings , So if we don't do it carefully , It's OK , take data Delete the folder and execute the following command again

<> Installation services

stay bin Execute under directory
mysqld --install [ service name ]
The following service name may not be written , The default name is mysql. of course , If you need to install multiple MySQL service , It can be distinguished by different names , such as mysql5 and

After an Zhuan , implement
net start mysql perhaps net stop mysql To start or stop the service

sc delete MySQL/mysqld -remove Used to unload MySQL service

<> Change password

Execute the order
mysql -u root -p
Press enter, Now let's enter the password , At this time, the input password is the password we generated above .
get into mysql, Execute the following command to change the password

ALTER USER ‘root’@‘localhost’ IDENTIFIED WITH mysql_native_password BY ‘ New password ’;
be careful : I want a semicolon after that , Or I'll wait for you to lose , Until we met ; end

This is the installation mysql8.0 Steps for , come on. !

©2019-2020 Toolsou All rights reserved,
Hikvision - Embedded software written test questions C Language application 0 The length of array in memory and structure is 0 In depth analysis data structure --- The preorder of binary tree , Middle order , Subsequent traversal How to do it ipad Transfer of medium and super large files to computer elementui Shuttle box el-transfer Display list content text too long 2019 The 10th Blue Bridge Cup C/C++ A Summary after the National Games ( Beijing Tourism summary )unity Shooting games , Implementation of first person camera python of numpy Module detailed explanation and application case Study notes 【STM32】 Digital steering gear Horizontal and vertical linkage pan tilt Vue Used in Element Open for the first time el-dialog Solution for not getting element