1P安装MySQL8.2报错,一直重启

https://dx8gxr4b7mj.feishu.cn/docx/J7epdqkSTodXtVxvTpncWHVmnUc?pre_pathname=%2Fdrive%2Fhome%2F

错误日志在这里

环境是wsl,其他都没最新版本

log

[2K1Panel-mysql-91AI  | mysqld: [Warning] World-writable config file '/etc/my.cnf' is ignored.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.410606Z 0 [System] [MY-015015] [Server] MySQL Server - start.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.701767Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.701810Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.2.0) starting as process 1
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.709192Z 0 [Warning] [MY-010159] [Server] Setting lower_case_table_names=2 because file system for /var/lib/mysql/ is case insensitive
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.740045Z 0 [Warning] [MY-000054] [Server] World-writable config file '/var/lib/mysql/auto.cnf' is ignored.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.741408Z 0 [Warning] [MY-010107] [Server] World-writable config file '/var/lib/mysql/auto.cnf' has been removed.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.742317Z 0 [Warning] [MY-010075] [Server] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: f8f41363-3d0c-11ef-a96c-0242ac120006.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:19.784867Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:22.901045Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
[2K1Panel-mysql-91AI  | mysqld: Table 'mysql.plugin' doesn't exist
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.389963Z 0 [ERROR] [MY-010735] [Server] Could not open the mysql.plugin table. Please perform the MySQL upgrade procedure.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.390443Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.390846Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.391318Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.391800Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.392164Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.392541Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:24.392988Z 0 [Warning] [MY-010441] [Server] Failed to open optimizer cost constant tables
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:25.317708Z 0 [Warning] [MY-010015] [Repl] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:25.929350Z 0 [Warning] [MY-010015] [Repl] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:26.028781Z 0 [Warning] [MY-013595] [Server] Failed to initialize TLS for channel: mysql_main. See below for the description of exact issue.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:26.028878Z 0 [Warning] [MY-010069] [Server] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
[2K1Panel-mysql-91AI  | mysqld: Cannot change permissions of the file 'private_key.pem.temp' (OS errno 1 - Operation not permitted)
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:26.506265Z 0 [ERROR] [MY-010295] [Server] Could not set file permission for private_key.pem
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:26.506332Z 0 [ERROR] [MY-010119] [Server] Aborting
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:29.023525Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.2.0)  MySQL Community Server - GPL.
[2K1Panel-mysql-91AI  | 2024-07-08T09:32:29.024745Z 0 [System] [MY-015016] [Server] MySQL Server - end.
[2K1Panel-mysql-91AI  | 2024-07-08 17:32:30+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.2.0-1.el8 started.
[2K1Panel-mysql-91AI  | 2024-07-08 17:32:32+08:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
[2K1Panel-mysql-91AI  | 2024-07-08 17:32:32+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.2.0-1.el8 started.
[2K1Panel-mysql-91AI  | mysqld: [Warning] World-writable config file '/etc/my.cnf' is ignored.

yml配置文件信息

networks:
    1panel-network:
        external: true
services:
    mysql:
        command:
            - --default-authentication-plugin=mysql_native_password
        container_name: ${CONTAINER_NAME}
        deploy:
            resources:
                limits:
                    cpus: ${CPUS}
                    memory: ${MEMORY_LIMIT}
        environment:
            MYSQL_ROOT_PASSWORD: ${PANEL_DB_ROOT_PASSWORD}
        image: mysql:8.2.0
        labels:
            createdBy: Apps
        networks:
            - 1panel-network
        ports:
            - ${HOST_IP}:${PANEL_APP_PORT_HTTP}:3306
        restart: always
        volumes:
            - ./data/:/var/lib/mysql
            - ./conf/my.cnf:/etc/my.cnf
            - ./log:/var/log/mysql
            - /etc/timezone:/etc/timezone:ro
            - /etc/localtime:/etc/localtime:ro

my.cnf

[mysqld]
skip-host-cache
skip-name-resolve
datadir=/var/lib/mysql
socket=/var/run/mysqld/mysqld.sock
secure-file-priv=/var/lib/mysql-files
user=mysql
log_error_suppression_list='MY-013360'

character_set_server=utf8
lower_case_table_names=1
group_concat_max_len=1024000
log_bin_trust_function_creators=1

pid-file=/var/run/mysqld/mysqld.pid
[client]
socket=/var/run/mysqld/mysqld.sock

!includedir /etc/mysql/conf.d/

临时性解决

yml配置如下(注释掉了两行):

networks:
    1panel-network:
        external: true
services:
    mysql:
        command:
            - --default-authentication-plugin=mysql_native_password
        container_name: ${CONTAINER_NAME}
        deploy:
            resources:
                limits:
                    cpus: ${CPUS}
                    memory: ${MEMORY_LIMIT}
        environment:
            MYSQL_ROOT_PASSWORD: ${PANEL_DB_ROOT_PASSWORD}
        image: mysql:8.2.0
        labels:
            createdBy: Apps
        networks:
            - 1panel-network
        ports:
            - ${HOST_IP}:${PANEL_APP_PORT_HTTP}:3306
        restart: always
        volumes:
            # - ./data/:/var/lib/mysql
            # - ./conf/my.cnf:/etc/my.cnf
            - ./log:/var/log/mysql
            - /etc/timezone:/etc/timezone:ro
            - /etc/localtime:/etc/localtime:ro

wsl

最终还得是权限问题