# XtraBackup 8.0.35-32 docker container error "Cannot create redo log files in read-only mode"

**URL:** <https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294>\
**Category:** Percona XtraBackup\
**Created:** [January 22, 2025, 2:57pm UTC](https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294 "2025-01-22T14:57:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![steffen](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@steffen](https://forums.percona.com/u/steffen)\
**Post date:** [January 22, 2025, 2:57pm UTC](https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294/1 "2025-01-22T14:57:22Z")

</div>

Hi,

I’m trying to set up an XtraBackup 8.0.35-32 docker container for use with a MySQL 8.0.40 (also in docker container) and get the following error:

```auto
xtrabackup | 2025-01-22T14:12:17.535798-00:00 0 [Note] [MY-011825] [Xtrabackup] recognized client arguments: --backup=1 --target-dir=/backup --host=dbXXX-db-1 --port=3306 --user=xtrabackup --password=* --keyring-file-data=/var/lib/mysql-keyring/keyring
xtrabackup | xtrabackup version 8.0.35-32 based on MySQL server 8.0.35 Linux (x86_64) (revision id: c339924a)
...
xtrabackup | 2025-01-22T14:12:17.729835-00:00 0 [Note] [MY-011825] [Xtrabackup] inititialize_service_handles suceeded
xtrabackup | 2025-01-22T14:12:17.835685-00:00 0 [ERROR] [MY-012889] [InnoDB] Cannot create redo log files in read-only mode (--innodb-read-only).

```

Exact command used in docker compose is

```auto
xtrabackup --backup --data-dir=/var/lib/mysql --target-dir=/backup --host=dbXXX-db-1 --port=3306 --user=xtrabackup --password=*** --keyring-file-data=/var/lib/mysql-keyring/keyring

```

The target directory is writeable from inside the container.

Is Percona XtraBackup 8.0.35-32 compatible with MySQL 8.0.40 Community edition?

---

<div class="post-metadata">

**Author:** ![satya.bodapati](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/satya.bodapati/32/1322_2.png) [@satya.bodapati](https://forums.percona.com/u/satya.bodapati)\
**Post date:** [January 23, 2025, 6:17pm UTC](https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294/2 "2025-01-23T18:17:22Z")

</div>

Yes, PXB 8.0.35 is forward compatible. So it should it work with 8.0.40

---

<div class="post-metadata">

**Author:** ![satya.bodapati](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/satya.bodapati/32/1322_2.png) [@satya.bodapati](https://forums.percona.com/u/satya.bodapati)\
**Post date:** [January 23, 2025, 6:18pm UTC](https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294/3 "2025-01-23T18:18:47Z")

</div>

Please check if the my.cnf has innodb-read-only parameter set

---

<div class="post-metadata">

**Author:** ![steffen](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@steffen](https://forums.percona.com/u/steffen)\
**Post date:** [January 24, 2025, 3:06pm UTC](https://forums.percona.com/t/xtrabackup-8-0-35-32-docker-container-error-cannot-create-redo-log-files-in-read-only-mode/36294/4 "2025-01-24T15:06:12Z")

</div>

Thanks for answering, but the cause seemed to be that xtrabackup requires to be run as root in the container.  
With “user: root” in docker-compose.yml it can write to the volume and the error is gone.  
Somewhat consufing, because the the backup volume’s base dir is created with “drwxrwxr-x 1001 root”, and xtrabackup seems to run as 1001 and should be able to write there.
