In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Editor to share with you this time is how to install and configure mysql 8.0.20 under Win10, the article is rich in content, interested friends can learn about it, I hope you can get something after reading this article.
MySQL download
MySQL can be downloaded directly from the official website. Choose the community version (free) to download and link.
Select Microsoft Windows in select operating system, and the latest version of MySQL appears below. It is currently MySQL 8.0.20. There are two zip files. Select the first Windows (x86, 64-bit), and ZIP Archive click the Download button on the right to download.
The download speed of the official website is sometimes slow. You can also download it by clicking on the link: mysql 8.0.20
Installation and configuration
Extract the downloaded package to an all-English directory. For example, I created a new MySQL folder on disk D and unzipped it to this folder, D:/MySQL.
Then add the path D:\ MySQL\ mysql-8.0.20-winx64 where mysql 8.0.20 is located to the environment variable Path
Next, formally install and configure MySQL:
(1) first, create a my.ini file under the D:\ MySQL\ mysql-8.0.20-winx64 path, create a new text document directly, and then rename it to my.ini.
Add the following to the document:
(pay attention to modifying the path of basedir and datadir)
[mysqld] # set port 3306 port=3306# set the installation directory of mysql basedir=D:\\ MySQL\\ mysql-8.0.20-winx64 # here set the decompression path of mysql # set the directory where the data of mysql database is stored datadir=D:\\ MySQL\\ mysql-8.0.20-winx64\\ Data # same as above, do not create a Data directory in the path yet The # maximum number of connections allowed is automatically generated during subsequent initialization. The number of times max_connections=200# allows connections to fail. This is to prevent anyone from attempting to attack the character set used by the max_connect_errors=10# server of the database system from this host. By default, the default storage engine default-storage-engine=INNODB# that UTF8character-set-server=utf8# will use when creating a new table uses the "mysql_native_password" plug-in authentication default_authentication_plugin=mysql_native_ password [MySQL] # to set the mysql client default character set default-character-set=utf8 [client] # setting. Set the port port=3306default-character-set=utf8 used by default when the mysql client connects to the server
(2) Open cmd with administrator privileges (be sure to open it with administrator privileges), and change the path to D:\ MySQL\ mysql-8.0.20-winx64\ bin
Microsoft Windows [Version 10.0.18363.815] (c) 2019 Microsoft Corporation. All rights reserved. C:\ Windows\ system32 > MySQL D:\ > cd MySQLD:\ MySQL > cd mysql-8.0.20-winx64D:\ MySQL\ mysql-8.0.20-winx64 > cd binD:\ MySQL\ mysql-8.0.20-winx64\ bin >
Type mysqld-- initialize-- console to initialize. In this step, you can get the initial password of mysql. The string after root@localhost is the initial password. Record it first and use it later.
D:\ MySQL\ mysql-8.0.20-winx64\ bin > mysqld-- initialize-- console2020-05-10T11:26:21.895908Z 0 [System] [MY-013169] [Server] D:\ MySQL\ mysql-8.0.20-winx64\ bin\ mysqld.exe (mysqld 8.0.20) initializing of server in progress as process 97642020-05-10T11:26:21.897278Z 0 [Warning] [MY-013242] [Server]-character-set-server: 'utf8' is currently an alias for the character set UTF8MB3 But will be an alias for UTF8MB4 in a future release. Please consider using UTF8MB4 in order to be unambiguous.2020-05-10T11:26:21.915225Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.2020-05-10T11:26:22.619057Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.2020-05-10T11:26:24.265774Z 6 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: 9Zh41zk-@mof
Enter mysqld-- install (if you need to install multiple mysql services, enter mysqld-- install [service name])
D:\ MySQL\ mysql-8.0.20-winx64\ bin > mysqld-- installService successfully installed.
If Service successfully installed is displayed, the installation is successful
Enter net start mysql to start the MySQL service
D:\ MySQL\ mysql-8.0.20-winx64\ bin > net start mysqlThe MySQL service is starting.The MySQL service was started successfully.
Enter mysql-u root-p, log in to mysql with the initial password, and enter the initial password after Enter password
D:\ MySQL\ mysql-8.0.20-winx64\ bin > mysql- u root-pEnter password: * Welcome to the MySQL monitor. Commands end with; or\ g.Your MySQL connection id is 8Server version: 8.0.20Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names may be trademarks of their respectiveowners.Type 'help;' or'\ h' for help. Type'\ c'to clear the current input statement.
After logging in, change the initial password so that you can set it to a password that is easy to remember.
Enter ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY' self-defined password; (semicolon must be taken)
Mysql > ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY' self-defined password; Query OK, 0 rows affected (0.02 sec)
At this point, it's done.
Enter show database; to see which data tables are included
Mysql > show databases +-+ | Database | +-+ | information_schema | | mysql | | performance_schema | | sys | +-+ 4 rows in set (0.01sec) finish reading this article on how to install and configure mysql 8.0.20 under Win10, if you think the article is well written You can share it with more people.
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.