MySQL 5.7.21 decompression version installation and configuration graphic tutorial

MySQL 5.7.21 decompression version installation and configuration graphic tutorial

This article records the detailed process of downloading and installing the decompressed version of MySQL 5.7.21 for your reference. The specific contents are as follows

1. First, unzip the MySQL version and download it from https://www.mysql.com/downloads/;

2. Unzip the installation package and choose the path according to your preference. The path I chose is E:\Java\java\MySQL, so the full path is E:\Java\java\MySQL\mysql-5.7.21-winx64

3. Configure environment variables

Add new system environment variables:

Key name: MYSQL_HOME

The value is: E:\Java\java\MySQL\mysql-5.7.21-winx64

Add in Path: %MYSQL_HOME%\bin. Note that the ";" symbol between different values ​​in Path cannot be omitted.

4. Prepare the my.ini file . You can create a new my.txt file first, and then rename the file to .ini. The previous version may have a my-default.ini file after decompression, but the 5.7.21 version does not have it, so you need to create the file manually. The content of the file is as follows:

[mysql] 
# Set the default character set of the mysql client to default-character-set=utf8 
[mysqld] 
#Set port 3306 port = 3306 
# Set the installation directory of mysql basedir=E:\Java\java\MySQL\mysql-5.7.21-winx64 
# Set the storage directory of mysql database data datadir=E:\Java\java\MySQL\mysql-5.7.21-winx64\data 
# Maximum number of connections allowed max_connections=200 
# The default character set used by the server is the 8-bit latin1 character set character-set-server=utf8 
# The default storage engine that will be used when creating a new table default-storage-engine=INNODB

Put the edited my.ini file in the E:\Java\java\MySQL\mysql-5.7.21-winx64 directory

5. Open the cmd command window as an administrator and switch the directory to the bin directory of the MySQL installation directory

6. Execute the following statement to install MySQL

mysqld -install

After executing the command, the prompt: Service successfully installed. indicates that the installation is successful

7. Execute the following statement to initialize MySQL

mysqld --initialize-insecure --user=mysql

After executing the command, a data directory will be generated under the MySQL installation directory and a root user will be created.

8. Execute the following command to start the mysql service

net start mysql

After execution, the following prompt will appear:

MySQL service is starting..

The MySQL service has been started successfully.

9. After starting MySQL, the root user's password is blank. Set the password with the following command:

mysqladmin -u root -p password new password
Enter password: Old password

When you need to enter the old password, since the old password is empty, just press Enter.

The decompressed version of MySQL 5.7.21 has been installed.

Wonderful topic sharing:

MySQL different versions installation tutorial

MySQL 5.7 installation tutorials for various versions

MySQL 5.6 installation tutorials for various versions

mysql8.0 installation tutorials for various versions

The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM.

You may also be interested in:
  • Detailed tutorial for installing mysql5.7.21 under Windows system
  • MySQL 5.7.21 winx64 installation and configuration method graphic tutorial
  • MySQL 5.7.21 installation and password configuration tutorial
  • MySQL 5.7.21 decompression version installation and configuration method graphic tutorial
  • MySQL 5.7.21 installation and configuration method graphic tutorial (window)
  • mysql installer web community 5.7.21.0.msi installation graphic tutorial
  • MySQL 5.7.21 winx64 free installation version configuration method graphic tutorial
  • MySQL 5.7.21 installation and configuration tutorial
  • MySQL 5.7.21 decompression version installation and configuration method graphic tutorial (win10)
  • MySQL 5.7.20\5.7.21 free installation version installation and configuration tutorial

<<:  Sample code for implementing Alipay sandbox payment with Vue+SpringBoot

>>:  Detailed explanation of the basic commands of Firewalld firewall in Centos7

Recommend

Teach you the detailed process of installing DOClever with Docker Compose

Table of contents 1. What is Docker Compose and h...

Solve the problem of black screen when starting VMware virtual machine

# Adjust VMware hard disk boot priority Step 1: E...

Advanced techniques for using CSS (used in actual combat)

1. The ul tag has a padding value by default in Mo...

Detailed explanation of how a SQL statement is executed in MySQL

Overview I have recently started learning MySQL r...

Use of Linux watch command

1. Command Introduction The watch command execute...

How to install Elasticsearch7.6 cluster in docker and set password

Table of contents Some basic configuration About ...

How to install vim editor in Linux (Ubuntu 18.04)

You can go to the Ubuntu official website to down...

JavaScript object-oriented class inheritance case explanation

1. Object-oriented class inheritance In the above...

Detailed explanation of writing and using Makefile under Linux

Table of contents Makefile Makefile naming and ru...

Common parameters of IE web page pop-up windows can be set by yourself

The pop-up has nothing to do with whether your cur...

How to achieve the maximum number of connections in mysql

Table of contents What is the reason for the sudd...