Xibo upgrade to 2.0.0. Cannot connect to MySQL server on "..."

CentOS 7.8.2003
Plesk Obsidian 18.0.28
Xibo 1.8.0
PHP 5.6.

Xibo was successfully upgraded from 1.4 to 1.8.0, but by version 1.8.0 I get an error by external database connection:

ERROR 2002 (HY000): Can't connect to MySQL server on '92.120.79.15' (115)

xibo-cms container console protocol

Settings for xibo-cms container:
PATH : /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
CMS_DEV_MODE : false
XMR_HOST tcp:// 92.120.79.15:32771
CMS_SERVER_NAME : xiboebo.rotz.dev
MYSQL_HOST : 92.120.79.15
MYSQL_USER : user
MYSQL_PASSWORD : password
MYSQL_PORT : 3306
MYSQL_DATABASE : database_name

Can someone guide me on what to check first of all to resolve Mysql connection problem? Or what information should I also provide to make the situation more clear?

changed MYSQL_HOST to 172.17.0.1, didn’t help either. What am I missing?

Waiting for MySQL to start - max 300 seconds
Waiting for MySQL to start - max 300 seconds
MySQL started
Updating settings.php
New install
Provisioning Database
Phinx by CakePHP - https://phinx.org. 0.9.2

using config file .varwwwcmsphinx.php
using config parser php
using migration paths

  • /var/www/cms/db/migrations
    warning no environment specified, defaulting to: production
    using adapter mysql
    using database database_name
    Configuring Database Settings
    Setting up Maintenance
    Protected Maintenance
    Importing ca-certs
    Setting up Quickchart
    Configuring Maintenance
    Removing web/install/index.php from production container
    Starting cron
    Starting webserver
    ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
    ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)

In MysqlAdapter.php line 115:

There was a problem connecting to the database: SQLSTATE[HY000] [2002] Oper
ation timed out

migrate [-c|–configuration CONFIGURATION] [-p|–parser PARSER] [-e|–environment ENVIRONMENT] [-t|–target TARGET] [-d|–date DATE] [-x|–dry-run]

ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
cp: can’t stat ‘/var/www/cms/ca-certs/.pem’: No such file or directory
cp: can’t stat '/var/www/cms/ca-certs/
.crt’: No such file or directory
WARNING: ca-certificates.crt does not contain exactly one certificate or CRL: skipping
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘172.17.0.1’ (115)
AH00558: httpd: Could not reliably determine the server’s fully qualified domain name, using 172.17.0.2. Set the ‘ServerName’ directive globally to suppress this message

or if localhost used, I get such an error:

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/run/mysqld/mysqld.sock' (2)

I’ve pulled 2 docker images in Plesk:

xibosignage/xibo-cms:release_1.8.0
xibosignage/xibo-xmr:release_1.8.0

settings for cms container I wrote in the first post. For xmr is nothing special, remains unchanged.

Firewall in Plesk is set to accept 92.120.79.15.

no config.env or what so ever used. I can’t figure it out where is my actuall stand according to Xibo Upgrade official documentation.

Someone?

So we officially support launching the containers with docker-compose - which is why you’re having issues relating the documentation to what you’re doing.

I’m not a Plesk user, so can’t advise on that, but the issue is that the Xibo CMS container can’t connect to the MySQL database with the IP and credentials you’ve given it.

You need to enter the correct credentials and IP for the container to connect.

I suspect Plesk runs its MySQL bound to only the loopback interface, in which case you’ll need to reconfigure it so that it’s accessible on a second interface the container can access - but be very careful because you need to ensure that you don’t then expose MySQL to the internet. You’ll need to ensure you firewall that off.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.