我已在 C:驱动器的默认位置中安装了运行MySql 8.0.19的工作台。我的数据文件夹为 D:\ MySQLData 。
在工作台中,我打开了选项文件 =>“安全性和设置”:
validate_password_check_user_name =关闭
validate-password = ON
它显示了一个弹出窗口:
---
+++
@@ -404,0 +405,2 @@
+validate_password_check_user_name = off
+validate_password.check_user_name = off
---
+++
@@ -407,0 +408 @@
+validate-password = ON
之后,当我重新启动服务时。这是未开始。
当我尝试使用安装程序重新配置时,它在Log As中显示错误: 例如,配置步骤:编写配置文件
Saving my.ini configuration file...
Saved my.ini configuration file.
Ended configuration step: Writing configuration file
Beginning configuration step: Updating Windows Firewall rules
Attempting to delete a Windows Firewall rule with command: netsh.exe advfirewall firewall delete rule name="Port 3306" protocol=TCP localport=3306
Deleted 1 rule(s).
Ok.
Adding a Windows Firewall rule for MySQL80 on port 3306.
Attempting to add a Windows Firewall rule with command: netsh.exe advfirewall firewall add rule name="Port 3306" protocol=TCP localport=3306 dir=in action=allow
Ok.
Successfully added the Windows Firewall rule.
Adding a Windows Firewall rule for MySQL80 on port 33060.
Attempting to add a Windows Firewall rule with command: netsh.exe advfirewall firewall add rule name="Port 33060" protocol=TCP localport=33060 dir=in action=allow
Ok.
Successfully added the Windows Firewall rule.
Ended configuration step: Updating Windows Firewall rules
Beginning configuration step: Adjusting Windows service
Attempting to grant Network Service require filesystem permissions.
Granted permissions.
Updating existing service
Existing service updated
Ended configuration step: Adjusting Windows service
Beginning configuration step: Initializing database (may take a long time)
Attempting to run MySQL Server with --initialize-insecure option...
Starting process for MySQL Server 8.0.19...
Starting process with command: C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe --defaults-file="C:\ProgramData\MySQL\MySQL Server 8.0\my.ini" --console --initialize-insecure=on --lower-case-table-names=1...
'NO_ZERO_DATE', 'NO_ZERO_IN_DATE' and 'ERROR_FOR_DIVISION_BY_ZERO' sql modes should be used with strict mode. They will be merged with strict mode in a future release.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.19) initializing of server in progress as process 9432
--initialize specified but the data directory has files in it. Aborting.
The designated data directory D:\MySQLData\ is unusable. You can remove all files that the server added to it.
Aborting
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.19) MySQL Community Server - GPL.
Process for mysqld, with ID 9432, was run successfully and exited with code 1.
Failed to start process for MySQL Server 8.0.19.
Database initialization failed.
Ended configuration step: Initializing database (may take a long time)
如何启动或重新配置而不会丢失我的数据库?