MySql 8.0.11-Winxp64 (free installation version) configuration tutorial

MySql 8.0.11-Winxp64 (free installation version) configuration tutorial

1. Unzip the zip package to the installation directory

First, unzip mysql-8.0.11-winx64.zip to the installation directory D:/mysql-8.0.11-winx64,

2. Configuration File

Add my.ini in the installation root directory

Basic configuration file (my)

[mysqld]
basedir = D:\mysql-8.0.11-winx64
datadir = D:\mysql-8.0.11-winx64\data
port = 3306
lower_case_table_names = 2
default_authentication_plugin=mysql_native_password

Reference basic configuration:

[mysqld]
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
# These are commonly set, remove the # and set as required.
basedir = D:\Program\MySQL
datadir = D:\DBs\MySQL
port = 3306
# server_id = .....
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M 
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES 
character-set-server = utf8mb4
performance_schema_max_table_instances = 600
table_definition_cache = 400
table_open_cache = 256
[mysql]
default-character-set = utf8mb4
[client]
default-character-set = utf8mb4

3. Initialize the database

Execute the command in the bin directory of the MySQL installation directory:

mysqld --initialize --console

After the execution is complete, the initial default password of the root user will be printed, for example:

2018-04-20T02:35:01.507037Z 0 [Warning] [MY-010915] [Server] 'NO_ZERO_DATE', 'NO_ZERO_IN_DATE' and 'ERROR_FOR_DIVISION_BY_ZERO' sql modes should be used with strict mode. They will be merged with strict mode in a future release.
2018-04-20T02:35:01.507640Z 0 [System] [MY-013169] [Server] D:\Program\MySQL8\bin\mysqld.exe (mysqld 8.0.11) initializing of server in progress as process 11064
2018-04-20T02:35:01.508173Z 0 [ERROR] [MY-010340] [Server] Error message file 'D:\Program\MySQL\share\english\errmsg.sys' had only 1090 error messages, but it should contain at least 4512 error messages. Check that the above file is the right version for this program!
2018-04-20T02:35:05.464644Z 5 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: APWCY5ws&hjQ
2018-04-20T02:35:07.017280Z 0 [System] [MY-013170] [Server] D:\Program\MySQL8\bin\mysqld.exe (mysqld 8.0.11) initializing of server has completed

Among them, "APWCY5ws&hjQ" in the fourth line is the initial password. Before changing the password, you need to remember this password as it will be needed for subsequent logins.

If you don't remember it, it's okay. Delete the initialized datadir directory and execute the initialization command again, and it will be regenerated. Of course, you can also use security tools to force a password change, using any method you like.

4. Installation service

Execute the command in the bin directory of the MySQL installation directory:

mysqld --install [服務名]

4. Start the service

net start MySQL

Change Password and Password Authentication Plugin

Execute the command in the bin directory of the MySQL installation directory:

mysql -uroot -p

At this time, you will be prompted to enter a password. Remember the password in step 3 and fill it in to log in successfully and enter the MySQL command mode.

Previously, the password authentication plugin for MySQL was "mysql_native_password", but now it uses "caching_sha2_password".

Because many database tools and link packages currently do not support "caching_sha2_password", for convenience, I temporarily changed back to the "mysql_native_password" authentication plug-in.

Execute the command in MySQL:

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

Modify the password verification plug-in and modify the password at the same time.

If you want to use the "mysql_native_password" plug-in authentication by default, you can configure the default_authentication_plugin item in the configuration file.

[mysqld]
default_authentication_plugin=mysql_native_password

Summarize

The above is the MySql 8.0.11-Winxp64 (free installation version) configuration tutorial introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!

You may also be interested in:
  • MySQL 8.0 installation and configuration tutorial
  • MySQL 8.0.11 installation summary tutorial diagram
  • Detailed installation tutorial of mysql-8.0.11-winx64.zip
  • Centos6.4 compile and install mysql 8.0.0 detailed tutorial
  • mysql8.0.11 winx64 manual installation and configuration tutorial
  • Centos6.5 online installation of mysql 8.0 detailed tutorial
  • MySql 8.0.11 installation and configuration tutorial
  • Detailed tutorial on installing MySQL 8.0 from source code on CentOS 7.4
  • mysql8.0.0 winx64.zip decompression version installation and configuration tutorial
  • MySQL 8.0.11 compressed version installation tutorial

<<:  Solution to Linux CentOS 6.5 ifconfig cannot query IP

>>:  How to view Linux ssh service information and running status

Recommend

Why MySQL chooses Repeatable Read as the default isolation level

Table of contents Oracle Isolation Levels MySQL I...

Detailed example of jQuery's chain programming style

The implementation principle of chain programming...

Share 9 Linux Shell Scripting Tips for Practice and Interviews

Precautions 1) Add interpreter at the beginning: ...

WeChat applet learning notes: page configuration and routing

I have been studying and reviewing the developmen...

Introducing icons by implementing custom components based on Vue

Preface In project development, there are many wa...

MySQL 5.7.18 installation tutorial under Windows

This article explains how to install MySQL from a...

MySQL 8.0.16 installation and configuration graphic tutorial under macOS

This article shares the installation and configur...

JavaScript implementation of carousel example

This article shares the specific code for JavaScr...

Detailed tutorial on installing nacos in docker and configuring the database

Environment Preparation Docker environment MySQL ...

Hyper-V Introduction and Installation and Use (Detailed Illustrations)

Preface: As a giant in the IT industry, Microsoft...

20 excellent foreign web page color matching cases sharing

This article collects 20 excellent web page color ...

Implementation of navigation bar and drop-down menu in CSS

1. CSS Navigation Bar (1) Function of the navigat...

Use of LRU algorithm in Vue built-in component keep-alive

Table of contents The use of Vue's keep-alive...