This article records the detailed tutorial of MySQL download and installation for your reference. The specific contents are as follows 1. To download the MySQL database, visit the official website: 2. Click MySQL Community Server under the Community module under the DOWNLOADS module to download. Since the latest version is: MySQL Community Server 5.7.21 It is recommended that bloggers download historical versions. This blog downloaded 5.6.39 Download steps: Enter and select the MySQL version and host Select the corresponding bit number according to your computer to download. This computer is 64-bit, so click download. Go to the next page, which requires you to register a MySQL account, but you can also download directly without registering. Click No thanks, just start my download and select the directory you want to download. 3. Configure the MySQL database. The configuration steps are as follows: There are two types of MySQL installation files, one in msi format and the other in zip format. The zip format needs to be decompressed by yourself. After decompression, MySQL can actually be used, but it needs to be configured. If the user does not configure and uses MySQL directly, the error shown in the figure will appear. This is because the environment variables are not configured. Configuring environment variables is simple: My Computer -> Properties -> Advanced -> Environment Variables Select PATH and add the path of your mysql bin folder after it: D:\Program Files\JavaTool\MySQL\mysql-5.6.39-winx64\bin After configuring the environment variables, you also need to modify the configuration file (if not configured, the error in the figure will appear when you start it later!: Error 2 The system cannot find the file). The default configuration file for mysql-5.6.1X is in D:\Program Files\JavaTool\MySQL\mysql-5.6.39-winx64my-default.ini, or you can create a my.ini file yourself. Modify or add configuration in it: basedir=D:\Program Files\JavaTool\MySQL\mysql-5.6.39-winx64 (the directory where mysql is located) datadir=D:\Program Files\JavaTool\MySQL\mysql-5.6.39-winx64\data (mysql directory\data) Note: The encoding of the my.ini file must be English encoding (such as ANSI in Windows), not UTF-8 or GBK. Run cmd as an administrator (it must be run as an administrator, otherwise the permissions are insufficient), Enter the command: cd D:\Program Files\JavaTool\MySQL\mysql-5.6.39-winx64\bin to enter the bin folder of mysql (regardless of whether the environment variables have been configured, you must enter the bin folder, otherwise error 2 will still be reported when starting the service later) Enter mysqld -install (If you do not run it as an administrator, an error will occur due to insufficient permissions: Install/Remove of the Service Denied!) Installation Successful Start the service and enter the command: net start mysql. As shown in the figure, the startup is successful. After the service is started successfully, enter the command: mysql -u root -p (there is no password for the first login, just press Enter)! Press Enter directly, as shown in the figure, the login is successful. Error summary: If an error occurs when starting the service, please see Note: Error 2 and Error 1067 often occur at this time. 1. If " Error 2 System cannot find file " appears, check whether the configuration file has been modified or whether the operation has been entered in the bin directory. If the configuration file has been modified correctly and entered the bin folder, you need to delete mysql first (enter mysqld -remove ) and then reinstall it (enter mysqld -install ); 2. If error 1067 appears, it means that the configuration file has been modified incorrectly. Please confirm whether the configuration file is correct. 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:
|
<<: Keepalived+Nginx+Tomcat sample code to implement high-availability Web cluster
>>: MAC+PyCharm+Flask+Vue.js build system
The MERGE storage engine treats a group of MyISAM...
Preface When backing up the database, a full data...
Pre-installation work: Make sure vmware workstati...
Table of contents Array destructuring assignment ...
The function I want to achieve is to open a new w...
The input box always displays the input history wh...
This article shares the specific code of jQuery t...
Basic concepts of consul Server mode and client m...
Table of contents Preface Why do we need to encap...
Last night, I was looking at an interview question...
In Ubuntu, you often encounter the situation wher...
MJML is a modern email tool that enables develope...
Preface ORDER BY 字段名升序/降序, I believe that everyon...
Prototype chain inheritance Prototype inheritance...
I have been quite free recently. I have been doin...