Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-18947

Diverse MySQL8 problems

    XMLWordPrintable

Details

    • Incident report
    • Status: Open
    • Trivial
    • Resolution: Unresolved
    • 5.2.4
    • None
    • Proxy (P), Server (S)
    • Debian 10.7
      MySQL 8 Group Replication

    Description

      OK, that's quite "edgy" and I found quite a number of things, not sure if that should be split into multiple discussions, but here we are.

      I am making a test scenario to install a MySQL 8 Replication cluster and run a Zabbix Server / Proxy against it. This should all be based on Debian.

      The first thing to be noticed is that, I have a cluster separated, but while installing the zabbix-proxy-mysql in my test, he also installs a MariaDB along with the DEB package, which is quite forceful and in my opinion that should be avoided.

      Second issue, is that the DEB package for zabbix-proxy-mysql, doesn't have a schema to create the zabbix-proxy database. (the one that should be in /usr/share/zabbix-proxy-mysql*/something.gz) There is no schema files that I could find.

      So while trying to create the database according to the zabbix documentation I get:

      MySQL localhost:3306 ssl zabbix_proxy SQL > create database zabbix_proxy DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci;
      Query OK, 1 row affected, 2 warnings (0.0053 sec)
      Warning (code 3719): 'utf8' is currently an alias for the character set UTF8MB3, but will be an alias for UTF8MB4 in a future release. Please consider using
      UTF8MB4 in order to be unambiguous.
      Warning (code 3778): 'utf8_general_ci' is a collation of the deprecated character set UTF8MB3. Please consider using UTF8MB4 with an appropriate collation in
      stead.
      

      ( I found another ticket here https://support.zabbix.com/browse/ZBX-17207 which this command was really smooth )

      I tried a few other variants but then anything really works, to I ignored the warning and tried to create the Tables like that.

      Then grabbing the schema.sql file from the source, when I try to create the database on MySQL8 cluster, I get:

      ERROR 3098 (HY000) at line 2022: The table does not comply with the requirements by an external plugin.
      

      From the whole file I found the error line is:

      INSERT INTO dbversion VALUES ('5020000','5020000');
      

      Which is very odd.

      Then I remember reading Vittorio Cioe (MySQL Senior Consultant) which explains on the presentation: https://assets.zabbix.com/files/zabbix_summit_2019/Vittorio_Cioe-Scaling_Zabbix_with_MySQL_InnoDB_Cluster.pdf on page 25, line in RED –

      Primary key/unique non-null key is required on every table.

      Therefore, changing the creation on that dbversion table to:

      CREATE TABLE "dbversion" (
       "mandatory" integer DEFAULT '0' NOT NULL,
       "optional" integer DEFAULT '0' NOT NULL,
       PRIMARY KEY (mandatory)
      ) ENGINE=InnoDB;
      

      So in resume:

      • DEB Package for proxy does not contain schema to create database;
      • MySQL have troubles to set Characterset and Collate and give several warnings (which might be a problem in the future?)
      • dbversion tables does not contain primary key, therefore have troubles with inserting data.

      Attachments

        Activity

          People

            agavrilovs Aleksandrs Petrovs-Gavrilovs
            spectroman jchegedus
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: