New installed Ubuntu 24.04.3. When I install MySQL 8.4 (percona-server-server8.4.5-5-1.noble), I got error message failed to start:
mysql.service: Referenced but unset environment variable evaluates to an empty string: MYSQLD_OPTS
I check /usr/lib/systemd/system/mysql.service, it contain line like ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS. I compare with other MySQL distributed, usually the line like ExecStart=/usr/sbin/mysqld. Deleting `$MYSQLD_OPTS` from systemd unit file (and systemctl daemon-reload), give error, but with different messages, and the mysql error log like:
2025-08-12T08:22:48.838632Z 0 [System] [MY-015015] [Server] MySQL Server - start.
2025-08-12T08:22:49.159932Z 0 [Warning] [MY-010097] [Server] Insecure configuration for --secure-log-path: Current value does not restrict location of generated files. Consider setting it to a valid, non-empty path.
2025-08-12T08:22:49.160049Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.4.5-5) starting as process 2962
2025-08-12T08:22:49.168431Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-08-12T08:22:49.575827Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
mysqld: Table ‘mysql.plugin’ doesn’t exist
2025-08-12T08:22:49.998367Z 0 [ERROR] [MY-010735] [Server] Could not open the mysql.plugin table. Please perform the MySQL upgrade procedure.
2025-08-12T08:22:49.999006Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:49.999651Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:49.999942Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.000275Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.000535Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.000785Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.001038Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.075605Z 0 [Warning] [MY-010015] [Repl] Gtid table is not ready to be used. Table ‘mysql.gtid_executed’ cannot be opened.
2025-08-12T08:22:50.139407Z 0 [Warning] [MY-010015] [Repl] Gtid table is not ready to be used. Table ‘mysql.gtid_executed’ cannot be opened.
2025-08-12T08:22:50.151449Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2025-08-12T08:22:50.151504Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2025-08-12T08:22:50.156885Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
2025-08-12T08:22:50.157195Z 0 [ERROR] [MY-013129] [Server] 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
2025-08-12T08:22:50.157236Z 0 [Warning] [MY-013129] [Server] 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.
2025-08-12T08:22:50.157422Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘default-authentication-plugin=mysql_native_password’.
2025-08-12T08:22:50.158217Z 0 [ERROR] [MY-010119] [Server] Aborting
2025-08-12T08:22:51.717521Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.4.5-5) Percona Server (GPL), Release ‘5’, Revision ‘3d3abca6’.
2025-08-12T08:22:51.717547Z 0 [System] [MY-015016] [Server] MySQL Server - end.