MySQL 8.0.13 installation and configuration method graphic tutorial under win10

MySQL 8.0.13 installation and configuration method graphic tutorial under win10

I would like to share the installation and configuration method of MySQL 8.0.13 with you, I hope it will be helpful to you.

1. Download the mysql-8.0.13 installation package

Download address, select the zip installation package to download.

2. Unzip to the directory you want to install

3. Create the my.ini configuration file

[mysqld]
#Port port = 3306
#mysql installation directory basedir = E:/amp/mysql8
#mysql data storage directory datadir = E:/amp/mysql8/data
#Maximum number of connections allowed max_connections = 1024
#The default character set used by the server is character-set-server = utf8mb4
#Default storage engine default-storage-engine = INNODB
#Service unique identifier server_id = 1
#Whether to enable slow query slow_query_log = 1
#Specify the path and name of the slow query log file slow_query_log_file = slow.log
#SQL statements will be recorded only if their execution time exceeds this value long_query_time = 10
#Open binlog log-bin = mysql-bin
#sql mode sql_mode = NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
 
#Note here that the default password verification plugin for mysql8 has been changed to caching_sha2_password
#For compatibility with the previous one, change back to mysql_native_password
default_authentication_plugin = mysql_native_password
 
[mysql]
default-character-set = utf8mb4
 
[client]
port = 3306
default-character-set = utf8mb4

4. Run the command line program as an administrator, enter the bin directory of mysql, and run the installation command

Without password:

mysqld --initialize-insecure --console

Automatically generate random passwords:

mysqld --initialize --console 

Install and start the service:

mysqld --install [service name]
net start [service name]

5. Use the randomly generated password above to log in to MySQL and change the root password

mysql -u root -p

Before mysql8.0.4, you can directly use the following method:

SET PASSWORD=PASSWORD('new password');

Starting from mysql8.0.4, only the following methods can be used:

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'new password';

Query user table information

select host,user,plugin from mysql.user; 

Since MySQL 8.0 cancels the syntax of directly granting users, you must create the user first and then grant.

create user 'username'@'host' identified with mysql_native_password by 'password';

Grant all permissions:

grant all privileges on *.* to 'username'@'host';

Set permissions as required:

grant select,insert,update,delete,create,drop,alert on *.* to 'username'@'password';

View user permissions:

show grants for 'username'@'host';

6. Finally, if necessary, you can add the mysql bin directory to the environment variables.

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:
  • MySQL 8.0.13 installation and configuration method graphic tutorial
  • MySQL 8.0.13 download and installation tutorial with pictures and text
  • MySQL 8.0.13 decompression version installation and configuration method graphic tutorial
  • Solve the problem when setting the date to 0000-00-00 00:00:00 in MySQL 8.0.13
  • Problems and solutions when installing MySQL8.0.13 on Win10 system
  • About MySQL 8.0.13 zip package installation method
  • MYSQL8.0.13 free installation version configuration tutorial example detailed explanation
  • MySQL 8.0.13 free installation version configuration tutorial under Windows environment
  • MySQL 8.0.13 installation and configuration method graphic tutorial under Windows 64 bit
  • MySQL 8.0.13 installation and configuration graphic tutorial

<<:  The solution record of Vue failing to obtain the element for the first time

>>:  Vue implements a simple shopping cart example

Recommend

MySQL database architecture details

Table of contents 1. MySQL Architecture 2. Networ...

HTML table markup tutorial (10): cell padding attribute CELLPADDING

Cell padding is the distance between the cell con...

MySQL chooses the appropriate data type for id

Table of contents Summary of Distributed ID Solut...

Nginx signal control

Introduction to Nginx Nginx is a high-performance...

Solve the black screen problem after VMware installs Linux system and starts

1. Installation environment 1. HUAWEI mate x cpu ...

The ultimate solution for writing bash scripts with nodejs

Table of contents Preface zx library $`command` c...

Let’s talk in detail about how browsers view closures

Table of contents Preface Introduction to Closure...

Detailed explanation of Vue's props configuration

<template> <div class="demo"&g...

JavaScript realizes the generation and verification of random codes

The generation and verification of random codes i...

How to operate MySql database with gorm

1. Setting case sensitivity of fields in the tabl...

The use of MySQL triggers and what to pay attention to

Table of contents About Triggers Use of triggers ...

Summary of js execution context and scope

Table of contents Preface text 1. Concepts relate...

JavaScript Basics Objects

Table of contents 1. Object 1.1 What is an object...