This article records the installation and configuration tutorial of MySQL5.6 under Windows 8 and shares it with everyone. 1.1 Download and path configuration First, go to the official website to download the MySQL installation package Select DOWNLOADS, Community version After downloading, unzip Add the address of the bin directory to the path in the environment variable. 1.3. Generate data file: Run cmd as administrator Enter C:\Users\lym96\Desktop\mysql-5.6.40-winx64\bin Execute the command: mysqld --initialize-insecure --user=mysql to generate the data directory in the C:\Users\lym96\Desktop\mysql-5.6.40-winx64 directory 1.4. Start the service: Execute the command: net start mysql to start the mysql service 1.5. Log in to mysql: Log in to mysql: (Because no password was set before, the password is blank, no need to enter a password, just press Enter) C:\Users\lym96\Desktop\mysql-5.6.40-winx64\bin>mysql -u root -p (-u username, -p password) Enter password: ****** 1.6. Set password mysql> set password=password('123456'); Query OK, 0 rows affected, 1 warning (0.00 sec) If you do not enter the password after logging in again, you will be prompted that you cannot log in. Remember: After entering a sentence in MySQL, you must end it with a semicolon The password should be 123456, then use mysql -uroot -p123456 1.7. Query user password: Query user password command: mysql> select host,user,authentication_string from mysql.user; 1.8. Exit mysql: mysql> quit Problem: Enter mysql -u root -p in the command line to log in to MySQL, and the error "Can't connect to MySQL server on localhost (10061)" is returned Solution : The reason is that mysql is not started Solution: 1. Add mysql to Windows services. Switch to the bin folder under the MySQL installation directory and run "mysqld --install" on the command line. 2. Initialize MySQL database 3. Enter net start mysql in the bin folder on the command line 4. Login Wonderful topic sharing: MySQL different versions installation tutorial MySQL 5.6 installation tutorials for various versions MySQL 5.7 installation tutorials for various versions mysql8.0 installation tutorials for various versions 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:
|
<<: Vue-pdf implements online preview of PDF files
>>: Implementation of single process control of Linux C background service program
When compiling and installing Nginx, some modules...
Table of contents We have written about drag and ...
Encapsulate a navigation bar component in Vue3, a...
Copy code The code is as follows: <style type=...
This article uses an example to illustrate the us...
This article aims to use the clearest structure t...
This article example shares the specific code of ...
1. How to construct? Let's review the common ...
Table of contents 1. Mathematical functions 2. St...
This article uses examples to illustrate the usag...
1. What is a proxy server? Proxy server, when the...
Install CentOS 7 after installing VirtualBox. I w...
Form provides two ways of data transmission - get ...
This article describes how to use docker to deplo...
need Add a paging bar, which can jump to the page...