Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Mysql5.7.20 installation and configuration method graphic text tutorial (win10)

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

This article shares the installation and configuration method of mysql 5.7.20 for your reference. The details are as follows

1. First of all, download it from MySql's official website.

Take the version I selected as an example (installation-free version), select MYSQL Community Server and then select your corresponding version on the right. Mine is 64-bit download the corresponding zip version.

After downloading, extract it to the location you want to store. Mine is extracted to D:\ mysql-5.7.20-winx64

After the decompression, there is no data file and my.ini configuration file, which need to be supplemented by yourself (there are additions below)

The next step is to set the environment variable. Mine is W10, open the system variable, configure the environment variable of mysql, the following figure is to open the system variable through the command line

Create the MYSQL_HOME variable, and the value of the variable is where you decompress it.

Add% MYSQL_HOME%\ bin; to the Path (notice the semicolon at the end)

Finally, the environment variable configuration of MySql is completed by saving.

Next, supplement the data file and my.ini.

Open cmd with an administrator in the D:\ mysql-5.7.20-winx64\ bin directory (there are several ways for an administrator to open cmd, one of which is via win+x and then select the command prompt (administrator) to open it, remember to go to the D:\ mysql-5.7.20-winx64\ bin directory in DOS) and run mysqld-- initialize-insecure-- user=mysql (note the spaces)

Then return to the directory and you will find the data directory.

Create a my.ini file with the content of (you don't have to follow the following text to do Baidu on your own, but it's all about the same content)

[client] port=3306default-character-set=utf8 [mysqld] # set to your MYSQL installation directory basedir=D:\ mysql-5.7.20-winx64# set to MYSQL data directory datadir=D:\ mysql-5.7.20-winx64\ dataport=3306character_set_server=utf8sql_mode=NO_ENGINE_SUBSTITUTION,NO_AUTO_CREATE_USER# enable query cache explicit_defaults_for_timestamp=trueskip-grant-tables

After completing the creation of the above two files, use the administrator to run the cmd input command mysqld-install under D:\ mysql-5.7.20-winx64\ bin. If Service successfully installed appears, the registration is successful.

Because I have already registered, the image above will appear when I run the command again.

The following figure appears when you run the net start mysql command (start the MYSQL command)

Net stop mysql command (stop MYSQL command)

At this point, you have completed the download and configuration of MySql.

The above is the whole content of this article, I hope it will be helpful to your study, and I also hope that you will support it.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report