没有不值得去解决的问题,也没有不值得去学习的技术!

Configuration for MySQL Server 8.0.39 Failed (Due to a Defect in mysql-installer-community-8.0.36.0.msi)

The configuration for MySOL Server 8.0.39 has failed.

作者:

在

, ,

1. The configuration for MySOL Server 8.0.39 has failed. As shown in Figure 1

The configuration for MySOL Server 8.0.39 has failed.
Figure 1

2. Check the log, as shown below

Plaintext
Beginning configuration step: Starting the server and upgrading system tables (may take a long time)

Attempting to start service MySQL80...
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.39) starting as process 15472
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
option 'mysqlx-port': unsigned value 0 adjusted to 1.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
InnoDB initialization has started.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.39) starting as process 15472
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
option 'mysqlx-port': unsigned value 0 adjusted to 1.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
InnoDB initialization has started.
InnoDB initialization has ended.
CA certificate ca.pem is self signed.
Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
unknown variable 'mysqlx_port=0.0'.
Aborting
InnoDB initialization has ended.
CA certificate ca.pem is self signed.
Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
unknown variable 'mysqlx_port=0.0'.
Aborting
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.39)  MySQL Community Server - GPL.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.39)  MySQL Community Server - GPL...................................
MySQL failed to start because of the following error(s):
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
unknown variable 'mysqlx_port=0.0'.
Aborting

只有在任务处于完成状态(RanToCompletion、Faulted 或 Canceled)时才能释放它。
Ended configuration step: Starting the server and upgrading system tables (may take a long time)

........................................................

3. Edit C:\ProgramData\MySQL\MySQL Server 8.0\my.ini.

Plaintext

# The TCP/IP Port the MySQL Server X Protocol will listen on.
mysqlx_port=33060

4. Right-click mysql-installer-community-8.0.36.0.msi to install, select MySOL Server, and click Reconfigure. As shown in Figure 2

Right-click mysql-installer-community-8.0.36.0.msi to install, select MySOL Server, and click Reconfigure
Figure 2

5. It still reported an error, but a different one this time. Successfully started service MySQL80. Ended configuration step: Starting the server and upgrading system tables (may take a long time). As shown in Figure 3

It still reported an error, but a different one this time. Successfully started service MySQL80. Ended configuration step: Starting the server and upgrading system tables (may take a long time)
Figure 3
Plaintext

Beginning configuration step: Starting the server and upgrading system tables (may take a long time)

Attempting to start service MySQL80...
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.39) starting as process 18132
InnoDB initialization has started.
InnoDB initialization has ended.
CA certificate ca.pem is self signed.
Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
X Plugin ready for connections. Bind-address: '::' port: 33060
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: ready for connections. Version: '8.0.39'  socket: ''  port: 3306  MySQL Community Server - GPL.
Successfully started service MySQL80.
The upgrade of system tables did not complete successfully. Check for errors in the log.
Ended configuration step: Starting the server and upgrading system tables (may take a long time)


6. Right-click mysql-installer-community-8.0.36.0.msi to install again, select MySOL Server, and click Reconfigure. As shown in Figure 4

Right-click mysql-installer-community-8.0.36.0.msi to install again, select MySOL Server, and click Reconfigure
Figure 4

7. The configuration step [Starting the server and upgrading system tables (may take a long time)] is taking longer than expected. It is advised to not cancel the configuration and wait. The configuration step [Starting the server and upgrading system tables (may take a long time)] is taking longer than expected. It is advised to not cancel the configuration and wait. I actually waited for a whole night and half a day, which was incredibly frustrating. During this time, the computer might have gone to sleep, and a popup prompted whether to cancel, so I didn’t manage to click the Wait button in time. As shown in Figure 5 and Figure 6

The configuration step [Starting the server and upgrading system tables (may take a long time)] is taking longer than expected. It is advised to not cancel the configuration and wait. The configuration step [Starting the server and upgrading system tables (may take a long time)] is taking longer than expected. It is advised to not cancel the configuration and wait. I actually waited for a whole night and half a day, which was incredibly frustrating
Figure 5

During this time, the computer might have gone to sleep, and a popup prompted whether to cancel, so I didn't manage to click the Wait button in time.
Figure 6

8. I finally decided to give up, restarted MySQL Installer as administrator, and uninstalled MySQL Server 8.0.39. As shown in Figure 7

I finally decided to give up, restarted MySQL Installer as administrator, and uninstalled MySQL Server 8.0.39
Figure 7

9. Click the Add button to reinstall. Initializing database (may take a long time) failed. As shown in Figure 8

Click the Add button to reinstall. Initializing database (may take a long time) failed
Figure 8

10. Check the Log: C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value ‘0.0’ to ‘mysqlx-port’. Parsing options for plugin ‘mysqlx’ failed.

Plaintext
Beginning configuration step: Writing configuration file

Saving my.ini configuration file...
Saved my.ini configuration file.
Ended configuration step: Writing configuration file

Beginning configuration step: Updating Windows Firewall rules

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
确定。


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
确定。


Successfully added the Windows Firewall rule.
Ended configuration step: Updating Windows Firewall rules

Beginning configuration step: Adjusting Windows service

Attempting to grant the required filesystem permissions to the 'NT AUTHORITY\NetworkService' account.
Granted permissions to the data directory.
Adding new service
New service added
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.39...
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....
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.39) initializing of server in progress as process 17772
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
option 'mysqlx-port': unsigned value 0 adjusted to 1.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
InnoDB initialization has started..
InnoDB initialization has ended..
unknown variable 'mysqlx_port=0.0'.
The newly created data directory C:\ProgramData\MySQL\MySQL Server 8.0\Data\ by --initialize is unusable. You can remove it.
Aborting.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.39)  MySQL Community Server - GPL.
Process for mysqld, with ID 17772, was run successfully and exited with code 1.
Failed to start process for MySQL Server 8.0.39.
Database initialization failed.
Ended configuration step: Initializing database (may take a long time)

........................................................................................................................

10. Repeat step 3, click Back, and then Execute again. No more errors were reported. Starting the server failed, so I repeated step 3 again and clicked Execute again. It still failed. As shown in Figure 9

Repeat step 3, click Back, and then Execute again. No more errors were reported. Starting the server failed, so I repeated step 3 again and clicked Execute again. It still failed
Figure 9
Plaintext
Beginning configuration step: Writing configuration file

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

已删除 1 规则。
确定。


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
确定。


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
确定。


Successfully added the Windows Firewall rule.
Ended configuration step: Updating Windows Firewall rules

Beginning configuration step: Adjusting Windows service

Attempting to grant the required filesystem permissions to the 'NT AUTHORITY\NetworkService' account.
Granted permissions to the data directory.
Adding new service
New service added
Ended configuration step: Adjusting Windows service

Beginning configuration step: Updating permissions for the data folder and related server files

Attempting to update the permissions for the data folder and related server files...
Found existing data directory, no need to initialize the database.
The data folder and related server files have already been updated.
Ended configuration step: Updating permissions for the data folder and related server files

Beginning configuration step: Starting the server

Attempting to start service MySQL80....
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.39) starting as process 17964
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
option 'mysqlx-port': unsigned value 0 adjusted to 1.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
InnoDB initialization has started.
InnoDB initialization has ended.
mysqld: Table 'mysql.plugin' doesn't exist
Could not open the mysql.plugin table. Please perform the MySQL upgrade procedure.
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Failed to open optimizer cost constant tables
Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
CA certificate ca.pem is self signed.
Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
Failed to open optimizer cost constant tables
A message intended for a client cannot be sent there as no client-session is attached. Therefore, we're sending the information to the error-log instead: MY-001146 - Table 'mysql.component' doesn't exist
A message intended for a client cannot be sent there as no client-session is attached. Therefore, we're sending the information to the error-log instead: MY-003543 - The mysql.component table is missing or has an incorrect definition.
unknown variable 'mysqlx_port=0.0'.
Aborting
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.39)  MySQL Community Server - GPL..................................................
只有在任务处于完成状态(RanToCompletion、Faulted 或 Canceled)时才能释放它。
Ended configuration step: Starting the server

..............................

11. I decided to use the system’s built-in uninstall feature, as shown in Figure 10 and Figure 11

I decided to use the system's built-in uninstall feature
Figure 10

 

I decided to use the system's built-in uninstall feature
Figure 11

12. Uninstall all MySQL-related software. As shown in Figure 12

Uninstall all MySQL-related software
Figure 12

13. When reinstalling, choose Custom. As shown in Figure 13

When reinstalling, choose Custom
Figure 13

14. Select version 8.0.36 for all. As shown in Figure 14

Select version 8.0.36 for all
Figure 14

15. It still failed, as shown in Figure 15

It still failed
Figure 15
Plaintext
Beginning configuration step: Writing configuration file

Saving my.ini configuration file...
Saved my.ini configuration file.
Ended configuration step: Writing configuration file

Beginning configuration step: Updating Windows Firewall rules

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
确定。


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
确定。


Successfully added the Windows Firewall rule.
Ended configuration step: Updating Windows Firewall rules

Beginning configuration step: Adjusting Windows service

Attempting to grant the required filesystem permissions to the 'NT AUTHORITY\NetworkService' account.
Granted permissions to the data directory.
Adding new service
New service added
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.36...
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...
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe (mysqld 8.0.36) initializing of server in progress as process 17052
Unknown suffix '.' used for variable 'mysqlx-port' (value '0.0').
option 'mysqlx-port': unsigned value 0 adjusted to 1.
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Error while setting value '0.0' to 'mysqlx-port'.
Parsing options for plugin 'mysqlx' failed.
InnoDB initialization has started.
InnoDB initialization has ended.
unknown variable 'mysqlx_port=0.0'.
The newly created data directory C:\ProgramData\MySQL\MySQL Server 8.0\Data\ by --initialize is unusable. You can remove it.
Aborting
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld.exe: Shutdown complete (mysqld 8.0.36)  MySQL Community Server - GPL.
Process for mysqld, with ID 17052, was run successfully and exited with code 1.
Failed to start process for MySQL Server 8.0.36.
Database initialization failed.
Ended configuration step: Initializing database (may take a long time)

16. Reference: MySql installation database initialization error . This is a bug in the 8.0.11 installer. Although the error was different, I decided to download the latest version of MySQL Installer, mysql-installer-community-8.0.39.0.msi. The installation succeeded, and no more errors were reported. As shown in Figure 16

This is a bug in the 8.0.11 installer. Although the error was different, I decided to download the latest version of MySQL Installer, mysql-installer-community-8.0.39.0.msi. The installation succeeded, and no more errors were reported
Figure 16

关于作者 · 持续学习与技术实践

我是一名拥有 15 年以上开发经验的技术从业者,自 2013 年起持续运营个人技术博客,记录工作与个人项目中遇到的真实问题,以及解决问题过程中的探索、实践和思考。

除了技术写作,我也在持续开发和维护自己的独立项目,探索新技术和新工具在实际场景中的应用。我始终相信,没有不值得去解决的问题,也没有不值得去学习的技术。

如果这篇文章对你有所帮助,欢迎浏览博客中的其他文章,也欢迎交流技术经验与想法。

关于我  ·  GitHub  ·  邮件联系