Windows 10 installed under mysql 5.7 and FAQs
1. Download
https://dev.mysql.com/downloads/mysql/
2, installation
- 2-1, unzip the file to the current directory
- 2-2, the environment variable settings do
- 2-3, modification increases my.nin
. 1 [Client] 2 # Set mysql client default character set . 3 default - Character - SET = UTF8 . 4 . 5 [mysqld] . 6 # 3306 port is provided . 7 Port = 3306 . 8 the character_set_server = UTF8 . 9 # unzipped 10 the basedir = D: \\ Software \ mysql57 . 11 # decompressed data directory the directory 12 is DATADIR = D: \\ Software \ mysql57 \ data 13 is default -storage-Engine INNODB = 14 15 the sql_mode = NO_ENGINE_SUBSTITUTION, the STRICT_TRANS_TABLES 16 . 17 [WinMySQLAdmin] 18 is D:\software\mysql57\bin\mysqld.exe
- 2-4, cmd into the bin directory, execute mysqld --initialize-insecure
- 2-5, execute mysqld -install
- 2-6、net start mysql
- 2-7, modify the password mysql SET PASSWORD FOR 'root' @ 'localhost' = PASSWORD ( '123456');
Error record 1: Address reprint https://blog.csdn.net/m_wise/article/details/70196039
1 Log mysql database occur when: 2 . 3 ERROR 1045 (28000): Access denied for User ' the ODBC ' @ ' localhost ' ( the using password: NO ) . 4 . 5 ERROR 1045 (28000): Access denied for User ' the ODBC ' @ ' localhost '( the using password: YES) . 6 . 7 under Windows, two or more wrong solution, and "access denied the system error" appears . 8 . 9 processing method; (ps: I personally test) 10 . 11 1. installation mysql directory file found in the my.ini configuration file, then right with Notepad, 12 is 13 is2. Open, mysqld keyword search 14 15 Once found, add skip- in mysqld under Grant -tables, save and exit. 16 17 PS: if not to save the prompt, you can cut the file to the desktop, and then save the changes to replicate directory mySQL 18 19 3. After saving the restart mySQL, 20 21 first check mysql service has not started. 22 23 start mysql service, 24- 25 (1) Right-click à à à managed to start my computer. 26 27 (2) when run with win + R cmd 28 29 enter net start mysql start mysql service time of a "system error 5. access Denied " 30 31 time 32 33 to find à right-click command prompt run as administrator à 34 35 enter net start mysql start mysql service 36 37 4. Enter mysql -u root -p password you can not log on, and appear password: When can directly enter into the. 38 is 39 5. The MySQL> use MySQL; Enter Database changed (modified database) 40 41 is 6. The MySQL> Update User setPassword = password ( " 123456 ") WHERE User = " the root "; Enter a password reset (here, the password is " 123456 ") Note: Remember the OK semicolon Query, RowsAffected 2 (0.09 sec). the rows Matched: 2 the Changed: 2 Warnings: 0 42 is 43 is 7. The MySQL> the flush privileges ; Enter refresh the OK Query, 0 rows affected (0.00 sec ) 44 45 8. The MySQL> quitBye Exit 46 is 47 PS: where 123456 is the new password, the user can modify their own password into 48 49 9. Finally my.ini earlier in this document, the addition of just a " skip- the Tables-Grant "line delete, save and exit and then restart the mysql service on it. 50 ---------------- 51 Copyright: This article is the original article CSDN bloggers "m_wise", following the 4.0 CC BY -SA copyright agreement, reproduced, please attach the original source and link this statement. 52 Original link: HTTPS: //blog.csdn.net/m_wise/article/details/70196039 53