Operating system win10 MySQL is the 64-bit zip decompressed Community version downloaded from the official website. Because I wanted to install Mysql on the company computer, I downloaded the latest version of Mysql-5.7.17 from the official website. First, I installed it according to the online tutorial, unzipped it, and then created a new Mysql0104 directory on the C drive (as the installation directory for Mysql), and copied the contents of the unzipped Mysql-5.7.17 folder to the installation directory Mysql. The file contents are as follows: Then follow the online guide: run the command line window as an administrator, and install mysql using mysqld -install; theoretically there should be no problem with this step and the installation should be normal. It will give feedback that the installation is successful (I forgot to take a screenshot of this step) To avoid unsuccessful subsequent installation, set up the configuration file first. Right-click on the MyPC computer, select Properties, click to enter and select Advanced System settings, click to enter and select Environment Variables, select the System variables selected in the red box in the figure below, New to add a system variable MYSQL_HOME, the value is the installation path of MySQL, on my computer the value is: C:\mysql0104, then click Path (generally there will be PATH on the computer, if not, create it yourself), then copy and paste the string of values ;%MYSQL_HOME%\bin, and the environment variable will be configured, as shown in the figure below. Next, you need to install and configure MySQL, which is different from the old version. Because there is no data file under the mysql0104 folder, we need the system to generate it. So run the command line window as administrator. Use the cd command to switch directories and make sure the directory is under the bin directory (there may be errors under the system directory, but I have not tried it). Enter the command in the bin directory: There is also a saying on the Internet that enter the command: I have made several mistakes in this step. If you make a mistake, just delete the data folder. Then run this line of code again. However, if there is a data folder, running the above initialization command will definitely result in an error. Initialization is very important. After executing the initialization command, the following files are newly generated in the empty data directory: Some people on the Internet say that you can copy the data files in the old version of MySQL to the installation directory, so there is no need to generate the system. However, I have seen many people say that this method will cause many problems, so it is not recommended. After all, different versions of updates should have some differences in the contents of the data folder. Then there is a step to start the mysql service, that is, net start mysql. Theoretically, it should start successfully, but I keep getting errors. And it was an error for unknown reasons. I struggled with this step for a long time, but later I found that in fact, I didn’t need to care about the feedback of this command at all, because as long as the database could operate normally, there would be no problem with anything else. Don't worry about it, let's check whether our mysql is actually installed successfully: Enter in the command line: Look, the system feedback shows that we have successfully logged into the database. After that, we can operate through some commands, such as: Then you can create tables, query, insert and delete in the database normally, and the MySQL environment is installed. The above is the graphic tutorial for installing Mysql 5.7.17 under win10 system 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:
|
<<: Linux server SSH cracking prevention method (recommended)
>>: Problems and solutions encountered when installing mininet on Ubuntu 16.04.4LTS
Project scenario: When running the Vue project, t...
Three knowledge points: 1. CSS descendant selecto...
Table of contents JS obtains the .txt file conten...
What is keepalive? In normal development, some co...
Preface Nginx is an HTTP server designed for perf...
Viewing and Setting SQL Mode in MySQL MySQL can r...
1. Install Docker yum -y install docker-io The &q...
Table of contents Principle Source code analysis ...
The operating environment of this tutorial: Windo...
1. Log in to VPN using IE browser 2. Remote login...
Unfortunately, the MYSQL_DATA_TRUNCATED error occ...
Later, I also added how to use Jupyter Notebook i...
Relationship between MySQL and MariaDB MariaDB da...
need: In the near future, we will implement the l...
2.1、msi installation package 2.1.1、Installation I...