如何修复 Docker MariaDB 不启动 "upgrade ... required but skipped due to $MARIADB_AUTO_UPGRADE"
问题:
你的 MariaDB / MySQL 容器因以下原因不启动
mariadb_entrypoint_log.txt
mariadb_1 | 2024-05-27 03:03:20+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:11.3.2+maria~ubu2204 started.
mariadb_1 | 2024-05-27 03:03:20+00:00 [Warn] [Entrypoint]: /sys/fs/cgroup///memory.pressure not writable, functionality unavailable to MariaDB
mariadb_1 | 2024-05-27 03:03:20+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
mariadb_1 | 2024-05-27 03:03:20+00:00 [Note] [Entrypoint]: Entrypoint script for MariaDB Server 1:11.3.2+maria~ubu2204 started.
mariadb_1 | 2024-05-27 03:03:21+00:00 [Note] [Entrypoint]: MariaDB upgrade information missing, assuming required
mariadb_1 | 2024-05-27 03:03:21+00:00 [Note] [Entrypoint]: MariaDB upgrade (mariadb-upgrade or creating healthcheck users) required, but skipped due to $MARIADB_AUTO_UPGRADE setting
mariadb_1 | 2024-05-27 3:03:21 0 [Warning] Could not increase number of max_open_files to more than 1024 (request: 32186)
mariadb_1 | 2024-05-27 3:03:21 0 [Warning] Changed limits: max_open_files: 1024 max_connections: 151 (was 151) table_cache: 421 (was 2000)解决方案
添加
docker-compose-mariadb-upgrade.yml
- MARIADB_AUTO_UPGRADE=1到你的 docker-compose.yml 的 environments 部分。
然后,重启容器。MariaDB 将自动升级自身。
Check out similar posts by category:
Docker
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow