Ad Widget

Collapse

Azure MariaDB suddenly won't connect

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Adam Stadnick
    Junior Member
    • Feb 2021
    • 12

    #1

    Azure MariaDB suddenly won't connect

    Starting at about 5PM on Tuesday this week, our previously 100% working Zabbix server instance in Azure has stopped.
    • The VM is running and accessible but the Zabbix UI reports that the Zabbix server is not running
    • The Zabbix server process is running
    • Setting the debuglevel to 5 and restarting the service shows what seems like normal startup, but it abruptly stops here: In DBconnect() flag:0
    • Manually connecting to the database from the server using the specified CA, user, and password in zabbix_server.conf works without issue
    • The dashboard is complaining that the MySQL version is too low (5.06.47 Minimum required MySQL database version is 5.07.28.). We are using Azure MariaDB-aaS which is on MariaDB 10.3.23, but the server version is reporting MySQL 5.06.47:
      • zabadmin@zabsrv01:/etc/zabbix$ sudo mariadb -u [email protected] -p -h zabdb.mariadb.database.azure.com
        Enter password:
        Welcome to the MariaDB monitor. Commands end with ; or \g.
        Your MySQL connection id is 63188
        Server version: 5.6.47.0 MariaDB Server

        Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

        Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

        MySQL [(none)]> select version();
        +---------------------+
        | version() |
        +---------------------+
        | 10.3.23-MariaDB-log |
        +---------------------+
        1 row in set (0.00 sec)
        MySQL [(none)]> use zabbix;
        Reading table information for completion of table and column names
        You can turn off this feature to get a quicker startup with -A

        Database changed
        MySQL [zabbix]> select * from dbversion;
        +-----------+----------+
        | mandatory | optional |
        +-----------+----------+
        | 5040000 | 5040000 |
        +-----------+----------+
        1 row in set (0.00 sec)
    According to Azure, our instance was moved around this time to new equipment. They are essentially refusing to provide support without a paid incident (we are working on this with our MS rep). This setup was 100% working until Tuesday afternoon. I have tried upgrading Zabbix just in case but of course that doesn't work since it can't talk to the database. I am going to try rolling the VM back to our backups but this seems like the database got broken by whatever Microsoft did and I don't think this is going to do much.

    Is there anything at all that I can do to get Zabbix to connect?
  • Adam Stadnick
    Junior Member
    • Feb 2021
    • 12

    #2
    After some fiddling, I was able to roll back the libmysqlclient21 driver to version 8.0.19 which allowed the connection to establish. Zabbix is still complaining about the mysql version being too low, but the actual DB version is correct. Zabbix's logic to check for DB versions is returning the version of the gateway rather than the database version, and Azure for some reason has their gateways set to some horrendously old version of MySQL. Their recommendation was to move to a flexible server deployment rather than the older instance, supposedly this gives more options for compatibility. I will give that a shot instead.

    Comment

    • Espenk
      Junior Member
      • Sep 2022
      • 4

      #3

      Hi,
      We have the same issue with Azure for Mysql single server. The version for the Paas Mysql is 8.
      When connecting with HeidiSQL and running select version(); it returns 8.0.15.Correct.
      When connecting remote with putty the version that that is default returned is 5.06.47. Incorrect.
      After entering the database remote and running in mysql>select version();
      8.0.15 is returned. Correct.
      So Zabbix will not start due to error Unsupported Db, too low version.
      Did you try with flexible server?
      Did it work there?
      Or did you find a work around for single server?

      Regards​

      Comment

      • Espenk
        Junior Member
        • Sep 2022
        • 4

        #4
        Found this.

        Comment

        • Espenk
          Junior Member
          • Sep 2022
          • 4

          #5
          Changed from db port 3306 to 3309 and it works.
          Correct version returned.

          Comment


          • pineapple
            pineapple commented
            Editing a comment
            Same thing here. 3309 looks fine
        • Espenk
          Junior Member
          • Sep 2022
          • 4

          #6
          Great to hear that pineapple. It was all in the MS docs.

          Comment


          • pineapple
            pineapple commented
            Editing a comment
            Yeah, probably would find it if it wasn't a quick first run with Azure MariaDB
            Anyway, you've saved few hours
        • Adam Stadnick
          Junior Member
          • Feb 2021
          • 12

          #7
          Sorry, I forgot about this thread (shame on me!) - I also was advised by support to use port 3309 and it is working now.

          Comment

          Working...