How to install and configure MySql in windows 10
Install the decompressed MySql database in windows 10
Step 1:Decompress the zip file to (my) D: \ MyGreenSoftware \ mysql-5.7.10-winx64
Step 2:Add environment variable (Windows 10 operating system): Right-click computer> Properties> advanced system Settings> environment variable find path and edit path to add it at the end; D: \ MyGreenSoftware \ mysql-5.7.10-winx64 \ bin
Step 3:Add the configuration file, locate the mysql-5.7.10-winx64 file in the decompressed directory of MySQL (for example, my D: \ MyGreenSoftware \ my-default.ini), and add
(Here you need to create a data folder under D: \ MyGreenSoftware \ mysql-5.7.10-winx64 \ data)
[mysqld]basedir=D:\MyGreenSoftware\mysql-5.7.10-winx64datadir=D:\MyGreenSoftware\mysql-5.7.10-winx64\data port = 3306
If the my-default.ini file is not found, create your own my. the ini file (first create a txt file and add the above four lines of code to save and then change the file suffix to ini) create a new text file txt and name it my. ini (note that the extension must also be modified ).
Step 4:Initialize the database. Open CMD as the administrator and run the following command (right-click cmd and run the following command as the administrator) mysqld-initialize-user = mysql-console
Console: [Note] A temporary password is generated for root @ localhost: XXXXXXX
XXXXXX is a randomly generated password (copied and saved)
Step 5:Add MySQL to the system service. Open CMD as an administrator and run the following command:
Mysqld-install MySQL and then execute the net start MySQL console. The service starts successfully.
Step 6:Change the password (a random string is generated, but it is easy to remember)
Run the mysql-u root-p command in the CMD console and press Enter. Enter the saved random password. After the command is successfully executed, the console displays mysql>
Then execute set password for root @ localhost = password ('20140901 ');
Your password has been changed to 123456
The above is all the content of this article. I hope it will be helpful for your learning and support for helping customers.