From 57edb3e30fd326cec89c8366aa524b508ad6ff04 Mon Sep 17 00:00:00 2001 From: Bitnami Bot Date: Mon, 12 Jun 2023 18:48:48 +0200 Subject: [PATCH] [bitnami/mariadb] Release 10.10.5-debian-11-r2 (#37387) Signed-off-by: Bitnami Containers --- bitnami/mariadb/10.10/debian-11/Dockerfile | 4 ++-- .../rootfs/opt/bitnami/scripts/libmariadb.sh | 2 +- bitnami/mariadb/README.md | 21 +++++++++++++++++++ 3 files changed, 24 insertions(+), 3 deletions(-) diff --git a/bitnami/mariadb/10.10/debian-11/Dockerfile b/bitnami/mariadb/10.10/debian-11/Dockerfile index 6425f49efbee..431bc89ba95b 100644 --- a/bitnami/mariadb/10.10/debian-11/Dockerfile +++ b/bitnami/mariadb/10.10/debian-11/Dockerfile @@ -3,10 +3,10 @@ FROM docker.io/bitnami/minideb:bullseye ARG TARGETARCH LABEL org.opencontainers.image.base.name="docker.io/bitnami/minideb:bullseye" \ - org.opencontainers.image.created="2023-06-10T21:17:04Z" \ + org.opencontainers.image.created="2023-06-12T16:26:38Z" \ org.opencontainers.image.description="Application packaged by VMware, Inc" \ org.opencontainers.image.licenses="Apache-2.0" \ - org.opencontainers.image.ref.name="10.10.5-debian-11-r1" \ + org.opencontainers.image.ref.name="10.10.5-debian-11-r2" \ org.opencontainers.image.title="mariadb" \ org.opencontainers.image.vendor="VMware, Inc." \ org.opencontainers.image.version="10.10.5" diff --git a/bitnami/mariadb/10.10/debian-11/rootfs/opt/bitnami/scripts/libmariadb.sh b/bitnami/mariadb/10.10/debian-11/rootfs/opt/bitnami/scripts/libmariadb.sh index fe290f338235..ce88e048f2d1 100644 --- a/bitnami/mariadb/10.10/debian-11/rootfs/opt/bitnami/scripts/libmariadb.sh +++ b/bitnami/mariadb/10.10/debian-11/rootfs/opt/bitnami/scripts/libmariadb.sh @@ -158,11 +158,11 @@ max_allowed_packet=16M bind_address=${DB_DEFAULT_BIND_ADDRESS} log_error=${DB_LOGS_DIR}/mysqld.log slow_query_log=${DB_ENABLE_SLOW_QUERY} -slow_query_log_file=${DB_LOGS_DIR}/mysqld.log long_query_time=${DB_LONG_QUERY_TIME} character_set_server=${DB_DEFAULT_CHARACTER_SET} collation_server=${DB_DEFAULT_COLLATE} plugin_dir=${DB_BASE_DIR}/lib/plugin +datadir=${DB_DATA_DIR} [client] port=${DB_DEFAULT_PORT_NUMBER} diff --git a/bitnami/mariadb/README.md b/bitnami/mariadb/README.md index fd33e5f944e1..35635fb8ec4a 100644 --- a/bitnami/mariadb/README.md +++ b/bitnami/mariadb/README.md @@ -344,6 +344,27 @@ By default MariaDB doesn't enable [slow query log](https://mariadb.com/kb/en/slo * `MARIADB_ENABLE_SLOW_QUERY`: Whether to enable slow query logs. Default: `0` * `MARIADB_LONG_QUERY_TIME`: How much time, in seconds, defines a slow query. Default: `10.0` +Slow queries information is logged to the `/-slow.log` file by default, and you can easily check it with the `mysqldumpslow` tool ([link to docs](https://mariadb.com/kb/en/mysqldumpslow/)): + +```console +$ docker run -d -e MARIADB_ENABLE_SLOW_QUERY=1 -e ALLOW_EMPTY_PASSWORD=yes --name my-mariadb-container bitnami/mariadb +# wait a bit for the initialization process... +$ docker exec -it my-mariadb-container mysqldumpslow +Reading mysql slow query log from /bitnami/mariadb/data/-slow.log +Count: 1 Time=0.01s (0s) Lock=0.00s (0s) Rows=0.0 (0), root[root]@localhost + GRANT ALL PRIVILEGES ON *.* TO 'S'@'S' WITH GRANT OPTION + +Count: 1 Time=0.01s (0s) Lock=0.00s (0s) Rows=0.0 (0), root[root]@localhost + CREATE USER 'S'@'S' + +Count: 1 Time=0.01s (0s) Lock=0.00s (0s) Rows=0.0 (0), root[root]@localhost + DELETE FROM mysql.user WHERE user not in ('S','S') + +Count: 1 Time=0.00s (0s) Lock=0.00s (0s) Rows=0.0 (0), root[root]@localhost + flush privileges +(...) +``` + ### Slow filesystems In some platforms, the filesystem used for persistence could be slow. That could cause the database to take extra time to be ready. If that's the case, you can configure the `MARIADB_INIT_SLEEP_TIME` environment variable to make the initialization script to wait extra time (in seconds) before proceeding with the configuration operations.