p>
p>
p>
p>
MYSQL error – Failed to find valid data directory
p>
operating environment: windows10
database version: mysql.8.0.16
problem description:
MySQL service is starting.
MySQL service cannot start. The
service did not report any errors.
solution:
- manually empty the files in the data folder under the installation path (possibly due to incomplete files due to previous initialization failure)
- into the bin path remove mysql service
- under the bin path enter mysqld –initialize-insecure (the program will create many files under the data folder)
- continue to enter mysqld -install (service has been reinstalled)
- start mysql service, enter net start mysql
p>
p>
the MYSQL error, Failed to find valid data directory. _Nikita – _failed CSDN blog to find valid data directory. p>
https://blog.csdn.net/Hellen0708/article/details/93377724
p>
p>
p>
=================================================================================
=================================================================================
=================================================================================
p>
the mysql database password _qq_26486949 blog blog – CSDN _mysql password p>
https://blog.csdn.net/qq_26486949/article/details/88373487
p>
p>
mysql database password Settings
p>
p>
p>
mysql newly installed does not have a password by default, so it needs to be set manually.
method 1: use the SET PASSWORD command
log in to MySQL first. p>
format: mysql> Set password for username @localhost = password(‘ new password ‘); p>
example: mysql> set password for root@localhost = password(‘123’); p>
p>
method 2: mysqladmin
format: mysqladmin-u username -p old password password new password
example: mysqladmin-uroot-p123456 password 123
p>
method 3: edit user table
directly with UPDATE
log in to MySQL first. p>
mysql> use mysql; p>
mysql> update user set password=password(‘123′) where user=’root’ and host=’localhost’; p>
mysql> flush privileges;
p>
method 4: use the GRANT statement mysql> Grant all on *.* to ‘root’@’localhost’ IDENTIFIED BY ‘your password ‘with grant option; mysql> flush privileges;
p>
method 5: when you forget the root password or initialize the password, you can do this:
Take Windows as an example:
1. Close the running MySQL service. p>
2. Open a DOS window and go to mysql\bin directory. p>
3. Enter mysqld –skip-grant-tables enter. Skip-grant-tables means to skip permission table authentication when starting MySQL service. p>
4. Open another DOS window (because the DOS window is no longer active) and go to the mysql\bin directory. p>
5. Enter mysql enter. If successful, mysql prompt > will appear. . p>
6. Connection permission database: use mysql; . p>
. Update user set password=password(“123″) where user=”root”; Don’t forget to put a semicolon at the end. p>
if ERROR 1054(42S22) Unknown column ‘password’ in ‘field list’ occurs, this is because the password field is no longer available in mysql database in version 5.7, and the password field is changed to authentication_string. The statement should be update User Set Authentication_string =password(“123″) where user=”root”;
7. Flush privileges (mandatory step) : flush privileges; . p>
8. Quit quit. p>
9. Log out of the system, enter again, log in with the username root and the new password 123 that you just set.
p>
p>
Read More:
- MySQL password setting error message: error 1054 (42s22): unknown column ‘password’ in ‘field list’
- MySQL forgot the root password
- MySQL 8 — error in setting simple password error 1819 (HY000): your password does not satisfy the current policy requirements
- MySQL ERROR 1054 (42S22): Unknown column’password’ in’field list’ error
- MySQL startup problem (ERROR 1045 (28000): Access denied for user’ODBC’@’localhost’ (using password: NO))
- After installing MySQL again under Linux, the solution of ‘MySQL module failed to start’ appears
- Navicat for MySQL error 1251 failed to connect to MySQL
- MySQL: if the remote connection using navicatip fails, prompt “is not allowed to connect to this MySQL server”
- MYSQL login error: mysqladmin: connect to server at’localhost’ failed
- Linux-mysql8.0 password reset problem – error 1396 (HY000): Operation alter user failed for ‘root’ @’localhost ‘
- MySQL — initialize failed to generate temporary password in error log after initialization
- MySQL error set: failed to start mysql.service : Unit mysql.service is masked.
- MYSQL:ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
- MySQL uses net start MySQL startup prompt (failed to start, the service did not report any error)
- MySQL local connection Error 1130_ The solution of MySQL 1130 error report when remote connection through Navicat for MySQL
- It can’t connect to local MySQL server through socket ‘/ tmp/ mysql.sock ‘(2) “;
- Modify the password of mysql8 on Windows
- MySQL error 1054 (42s22) unknown column ‘password’ in ‘field list’
- MySQL – ERROR 1146 (42S02): Table ‘mysql.user’ doesn’t exist
- The MySQL service suddenly hangs up with the error message can’t connect to MySQL server on ‘localhost’ (10061)