A tutorial for beginners to install and log in to mysql-8.0.19-winx64 (must-read for beginners)

A tutorial for beginners to install and log in to mysql-8.0.19-winx64 (must-read for beginners)

1. Download the installation package (64-bit)

MySQL official website download link: https://www.mysql.com/cn/

Click to download

Drop down to insert image description here

Scroll down and find the link below

insert image description here

Click on the above link and find the link below

insert image description here

Select the version shown in the picture and click Download.

insert image description here

insert image description here

2. Install MySQL database

Unzip the installation package. Here I unzip the installation package to the MySQL folder on drive D.

insert image description here

Configuring environment variables

(1) Right-click My Computer -> Properties -> Advanced System Settings -> Environment Variables. (2) Select New in System Variables.

insert image description here

(3) Enter the content in the figure below (the variable value changes according to the decompression path of your installation package).

insert image description here

(4) Find Path in the system variables and select Edit.

insert image description here

(5) Click New and enter %MYSQL_HOME%\bin.

insert image description here

3. Configure and initialize the my.ini file

(1) Create a new text document in the folder after unzipping the installation package and rename it to my.ini.

insert image description here

(2) Write the following configuration into the my.ini file.

[mysqld]
# Set port 3306 port=3306

# Customize the installation directory of MySQL, that is, the directory where you unzip the MySQL compressed package basedir=D:\MySQL\mysql-8.0.19-winx64

# Customize the data storage directory of the MySQL database datadir=D:\MySQL\mysql-8.0.19-winx64\data

# Maximum number of connections allowed max_connections=200

# The number of connection failures allowed is to prevent someone from trying to attack the database system from this host max_connect_errors=10

# The default character set used by the server is UTF8
character-set-server=utf8

(The basedir and datadir paths are written according to their actual paths.)

4.

(1) Run the command prompt as an administrator

insert image description here

(2) Execute the following command in the bin directory of the MySQL installation directory:

mysqld --initialize --console 

insert image description here

The second box contains the default initial password, which you need to remember as it will be used later.

(3) Enter the following command:

mysqld --install

insert image description here

(4) Enter the following command to start MySQL.

net start mysql

insert image description here

(5) Change the initial password. Enter the following command:

mysql -uroot -p

insert image description here

Enter the password in the box above. The password is the initial password noted in step (2) above. Enter the following command to change the password to your own:

alter user 'root'@'localhost' identified by 'jb51jb51';

insert image description here

The second arrow points to your password. You can modify csdncsdn in the above command to your own password according to your actual situation.

(6) Enter exit to exit MySQL and re-enter your password to verify whether the login is successful.

insert image description here

(7) Log out and terminate the MySQL service.

insert image description here

Summarize

This is the end of this article about the illustrated tutorial for beginners to install and log in to mysql-8.0.19-winx64 (a must-read for novices). For more relevant mysql-8.0.19-winx64 installation and login content, please search for previous articles on 123WORDPRESS.COM or continue to browse the related articles below. I hope everyone will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • Solve the installation problem of mysql8.0.19 winx64 version
  • Problems encountered when installing mysql-8.0.19-winx64: Can't create directory ''xxxx\Database\''
  • MySQL 8.0.19 winx64 installation tutorial and change the initial password under Windows 10
  • mysql 8.0.19 winx64.zip installation tutorial

<<:  Download and install VSCode on Linux and use programming to output the current time

>>:  JavaScript function call, apply and bind method case study

Recommend

Detailed installation process of nodejs management tool nvm

nvm nvm is responsible for managing multiple vers...

Introduction to the functions and usage of value and name attributes in Html

1. The value used in the button refers to the text...

Vue calls the computer camera to realize the photo function

This article example shares the specific code of ...

Use CSS to achieve circular wave effect

I often see some circular wave graphics on mobile...

Difference between querySelector and getElementById methods in JS

Table of contents 1. Overview 1.1 Usage of queryS...

How to import/save/load/delete images locally in Docker

1. Docker imports local images Sometimes we copy ...

Linux installation Redis implementation process and error solution

I installed redis today and some errors occurred ...

Example of using javascript to drag and swap div positions

1 Implementation Principle This is done using the...

MySQL Database Iron Laws (Summary)

Good database specifications help reduce the comp...

Web design and production test questions and reference answers

<br />Web Design and Production Test Part I ...

How to create a file system in a Linux partition or logical volume

Preface Learn to create a file system on your sys...

How to upgrade https under Nginx

Purchase Certificate You can purchase it from Ali...

How to dynamically add modules to Nginx

Written in front Often, after we install Nginx ba...

Example code for text origami effect using CSS3

Preface This article mainly shares with you an ex...