Preface You will encounter many problems when installing MySQL. There are many solutions to the problems on the blog. Here I attach some links. Friends who encounter problems can read them for reference. This article is mainly aimed at newbies who are new to the database to install the MySQL database. Currently, the official website has MySQL versions 5.5, 5.6, 5.7 and 8. When developing, we usually choose 1 to 2 versions lower than the latest version, so I chose 5.7 as the database to be installed. 1. Download steps 1. Visit the official website: https://www.mysql.com/ 2. Download the corresponding version Click on MySQL Community Server in the picture above to enter the download interface: Find the link for MySQL Community Server 5.7 and click on it: Choose to download the corresponding ZIP file according to the version of your computer. My computer is 64-bit, so I choose this to download. Click Download to enter the following interface: Click No thanks, just start my download , and then start downloading After downloading, unzip the file to the disk and directory you want to save it to. I unzipped the file to the E:\Program Files\MySQL directory. The above completes all the downloading work. 2. Configure environment variables1. System -> Advanced System Settings -> Environment Variables -> System Variables Click New , name the variable: MYSQL_HOME , add the location of your mysql-5.7.27-winx64 folder. 2. Edit Path and copy
3. Configure the my.ini fileCreate a new my.ini file in your mysql-5.7.27-winx64 directory. I created it in the E:\Program Files\Mysql\mysql-5.7.27-winx64 directory. The content of the my.ini file is: [mysqld] #Port number port = 3306 #mysql-5.7.27-winx64 path basedir=E:\Program Files\Mysql\mysql-5.7.27-winx64 #mysql-5.7.27-winx64 path + \data datadir=E:\Program Files\Mysql\mysql-5.7.27-winx64\data #Maximum number of connections max_connections=200 #Encoding character-set-server=utf8 default-storage-engine=INNODB sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES [mysql] #Encoding default-character-set=utf8 After the creation is complete, proceed to the next step. 4. Install MySQL1. Enter cmd in the input box and run it as an administrator . Note that you must run it as an administrator . Otherwise, during the installation process, the error "Install/Remove of the Service Denied!" will appear due to insufficient administrative privileges. This is very important! 1. Enter the E:\Program Files\Mysql\mysql-5.7.27-winx64\bin directory in cmd : Enter the installation command: Then continue to enter the command: Enter the startup command again: 5. Set MySQL password 1. Setting a password here is mainly to solve the problem of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO) 3. Find my.ini in the E:\Program Files\Mysql\mysql-5.7.27-winx64 directory, add 4. Restart MySQL and enter the startup command: Enter the command Entering MySQL successfully! Haha, it’s worth being happy after reaching this step! 5. Enter the command line 6. Enter the command line update 7. Manually stop the MySQL service, enter service in the win10 search bar and find MySQL . Right click and click Stop. Then delete the skip-grant-tables line in the my.ini file just now, save and close. 8. Start cmd again (as administrator), enter the startup command: Then enter the command line Since the password has not been reset, just reset it by typing the command line Summarize Including the time I spent writing the blog, it took me about 4 hours to install this database. The reason is that I encountered many problems during the installation. I will summarize them here and attach the solution links: This is the end of this article about the detailed download, installation and configuration tutorial of MySQL 5.7.27. For more relevant MySQL 5.7.27 download, installation and configuration content, please search 123WORDPRESS.COM's previous articles or continue to browse the following related articles. I hope everyone will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: Configure selenium environment based on linux and implement operation
>>: Native js to achieve accordion effect
It is difficult to find good image material websi...
It’s great to use CSS to realize various graphics...
Brief description Suitable for readers: Mobile de...
The format of textarea can be saved to the databas...
Preface: In the MySQL system, there are many diff...
Table of contents 1. Basic principles 2. Specific...
This article example shares the specific code of ...
This article records the installation and configu...
As the most commonly used layout element, DIV play...
This article example shares the specific code of ...
Unable to load dynamic library under Linux When t...
This article introduces Nginx from compilation an...
First look at the effect diagram: The complete co...
Table of contents Preface Case: Imitation of JD.c...
introduction The company's recent Vue front-e...