Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Installation / Database Schema Update 2013061000 Fails #263

Open
2 tasks done
LeeThompson opened this issue Aug 16, 2024 · 6 comments
Open
2 tasks done

New Installation / Database Schema Update 2013061000 Fails #263

LeeThompson opened this issue Aug 16, 2024 · 6 comments

Comments

@LeeThompson
Copy link

Prerequisites

  • I have searched for duplicate or closed issues
  • I can recreate the issue with all plugins disabled

Describe the issue

This is using the roundcube/roundcubemail:latest docker image installed today.

I setup MariaDB (MySQL compatible) and linked Roundcube to it.
I created the database as per the Roundcube's Github Wiki instructions (CREATE DATABASE roundcubemail CHARACTER SET utf8 COLLATE utf8_general_ci;)

When I started Roundcube's container up it connects to the database and starts working on the schema, but then fails for some reason and errors out.
Since it doesn't actually say what happened, it's impossible to troubleshoot this.
The docker hub distribution does not include a sql file with the schema, I'm going to download the regular distribution that includes it and hope I can recover that way.
Currently, out of the box, this doesn't seem to work with MySQL type installations.

2024/08/15 19:22:53 | stdout | Updating database schema (2013011000)... [OK]
2024/08/15 19:22:53 | stdout | Updating database schema (2013042700)... [OK]
2024/08/15 19:22:55 | stdout | Updating database schema (2013052500)... [OK]
2024/08/15 19:22:55 | stdout | Updating database schema (2013061000)... [FAILED]
2024/08/15 19:22:55 | stdout | ERROR: Error in DDL upgrade 2013061000: [1146] Table 'roundcubemail.cache' doesn't exist

What browser(s) are you seeing the problem on?

No response

What version of PHP are you using?

7.2 (whatever is in the official docker image)

What version of Roundcube are you using?

1.6.8

JavaScript errors

No response

PHP errors

No response

@alecpl alecpl transferred this issue from roundcube/roundcubemail Aug 16, 2024
@alecpl
Copy link
Member

alecpl commented Nov 18, 2024

Looks like it executes db schema upgrade instead of initialization, but I have no clue about docker images.

@pabzm I lost ability to transfer issues to roundcubemail-docker repo.

@pabzm
Copy link
Member

pabzm commented Nov 20, 2024

@LeeThompson Please try with an up to date image. If the problem still exists, please show us more details about how you connect the containers, and the full log output.

@alecpl I'm not aware of any changes in this regard. Do you happen to know which setting this might be due to?

@LeeThompson
Copy link
Author

@pabzm I am afraid I got it working by getting a hold of the schema files setting up the database using phpMyAdmin by hand so my installation no longer has this issue. It should be easy enough to test, though, just do a clean docker container setup.

@pabzm
Copy link
Member

pabzm commented Nov 25, 2024

@LeeThompson Actually the instructions in the wiki do tell that you have to initialize the database like you did later.

And using fresh setups following the examples or docs I cannot reproduce this problem – only by using a manipulated DB.

Following the code brings me to the understanding that you somehow must have created a table system, but didn't populate it – the container entrypoint calls bin/initdb.sh with --update, so that script looks into the database if there's a system table, and only if so runs the DB update code, which fails because it expects a pre-populated DB.

Does that ring a bell?

Either way, this hasn't got much to do with using containers, I think.

@ibaraki-douji
Copy link

Hey, got the same issue, i wanted to setup a test mail client in local.
Tho no, i did not run any db init.

I had a fresh mysql container with a default DB and the roundcube container.
Basicly, i took the docker-compose-mysql.yaml example and just ran it to get the error.

@pabzm
Copy link
Member

pabzm commented Jan 9, 2025

I still cannot reproduce.

Here's the output of running docker compose -f docker-compose-mysql.yaml up as of the "master" branch of today with the latest images.

@ibaraki-douji Can you please post the exact steps you did that brought up the problem, so we can reproduce it? And please tell us which platform (Docker? Which version?) and OS you are working on.

docker compose up username examples % docker compose -f docker-compose-mysql.yaml up WARN[0000] /Users/username/projects/nc/roundcubemail-docker/examples/docker-compose-mysql.yaml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion [+] Running 2/2 ✔ Container roundcubemail Created 0.0s ✔ Container roundcubedb Recreated 0.2s Attaching to roundcubedb, roundcubemail roundcubedb | 2025-01-09 11:31:54+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 9.1.0-1.el9 started. roundcubemail | roundcubemail found in /var/www/html - installing update... roundcubemail | Target installation already in version 1.6.9. Do you want to update again? (y/N) roundcubedb | 2025-01-09 11:31:54+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql' roundcubedb | 2025-01-09 11:31:54+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 9.1.0-1.el9 started. roundcubedb | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock' roundcubedb | 2025-01-09T11:31:54.869743Z 0 [System] [MY-015015] [Server] MySQL Server - start. roundcubedb | 2025-01-09T11:31:55.075017Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 9.1.0) starting as process 1 roundcubedb | 2025-01-09T11:31:55.076531Z 0 [Warning] [MY-010159] [Server] Setting lower_case_table_names=2 because file system for /var/lib/mysql/ is case insensitive roundcubedb | 2025-01-09T11:31:55.081183Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. roundcubedb | 2025-01-09T11:31:55.273158Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. roundcubedb | 2025-01-09T11:31:55.418993Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. roundcubedb | 2025-01-09T11:31:55.419040Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. roundcubedb | 2025-01-09T11:31:55.421087Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory. roundcubedb | 2025-01-09T11:31:55.437947Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock roundcubedb | 2025-01-09T11:31:55.437977Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '9.1.0' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL. roundcubemail | Copying files to target location...done. roundcubemail | roundcubemail | Running update script at target... roundcubemail | Executing database schema update. roundcubemail | /usr/bin/composer roundcubemail | Executing /usr/bin/composer to update dependencies... roundcubemail | Composer could not detect the root package (roundcube/roundcubemail) version, defaulting to '1.0.0'. See https://getcomposer.org/root-version roundcubemail | Loading composer repositories with package information roundcubemail | Updating dependencies roundcubemail | Lock file operations: 0 installs, 4 updates, 0 removals roundcubemail | - Upgrading guzzlehttp/promises (2.0.3 => 2.0.4) roundcubemail | - Upgrading pear/pear-core-minimal (v1.10.15 => v1.10.16) roundcubemail | - Upgrading roundcube/plugin-installer (0.3.8 => 0.3.9) roundcubemail | - Upgrading symfony/deprecation-contracts (v2.5.3 => v3.5.1) roundcubemail | Writing lock file roundcubemail | Installing dependencies from lock file roundcubemail | Package operations: 0 installs, 4 updates, 0 removals roundcubemail | - Downloading roundcube/plugin-installer (0.3.9) roundcubemail | - Downloading symfony/deprecation-contracts (v3.5.1) roundcubemail | - Downloading guzzlehttp/promises (2.0.4) roundcubemail | - Downloading pear/pear-core-minimal (v1.10.16) roundcubemail | 0/4 [>---------------------------] 0% roundcubemail | 3/4 [=====================>------] 75% roundcubemail | 4/4 [============================] 100% roundcubemail | - Upgrading roundcube/plugin-installer (0.3.8 => 0.3.9): Extracting archive roundcubemail | - Upgrading symfony/deprecation-contracts (v2.5.3 => v3.5.1): Extracting archive roundcubemail | - Upgrading guzzlehttp/promises (2.0.3 => 2.0.4): Extracting archive roundcubemail | - Upgrading pear/pear-core-minimal (v1.10.15 => v1.10.16): Extracting archive roundcubemail | 0/3 [>---------------------------] 0% roundcubemail | 3/3 [============================] 100% roundcubemail | Generating autoload files roundcubemail | 4 packages you are using are looking for funding. roundcubemail | Use the `composer fund` command to find out more! roundcubemail | No security vulnerability advisories found. roundcubemail | This instance of Roundcube is up-to-date. roundcubemail | Have fun! roundcubemail | All done. roundcubemail | Composer could not detect the root package (roundcube/roundcubemail) version, defaulting to '1.0.0'. See https://getcomposer.org/root-version roundcubemail | Installing dependencies from lock file roundcubemail | Verifying lock file contents can be installed on current platform. roundcubemail | Nothing to install, update or remove roundcubemail | Generating optimized autoload files roundcubemail | 4 packages you are using are looking for funding. roundcubemail | Use the `composer fund` command to find out more! roundcubemail | wait-for-it.sh: waiting 30 seconds for roundcubedb:3306 roundcubemail | wait-for-it.sh: roundcubedb:3306 is available after 0 seconds roundcubemail | Write Docker config to /var/www/html/config/config.docker.inc.php roundcubemail | Checking for database schema updates... roundcubemail | Generating locales (this might take a while)... roundcubemail | en_US.UTF-8... done roundcubemail | Generation complete. roundcubemail | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.23.0.3. Set the 'ServerName' directive globally to suppress this message roundcubemail | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.23.0.3. Set the 'ServerName' directive globally to suppress this message roundcubemail | [Thu Jan 09 11:31:59.363022 2025] [mpm_prefork:notice] [pid 1:tid 1] AH00163: Apache/2.4.62 (Debian) PHP/8.1.31 configured -- resuming normal operations roundcubemail | [Thu Jan 09 11:31:59.363043 2025] [core:notice] [pid 1:tid 1] AH00094: Command line: 'apache2 -D FOREGROUND'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants