Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-24234

gtid_strict_mode is not compatible with intermediate primary servers

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.2.36, 10.3.27, 10.4.17, 10.5.8
    • 10.4, 10.5
    • Replication

    Description

      As far as I can tell, gtid_strict_mode is not compatible with topologies that contain an intermediate primary server. Let's say that we have a topology like this:

      M1 -> M2 ----> S1 ... SN
      

      Let's say that M1 has gtid_domain_id=5 and M2 has gtid_domain_id=0.

      When you want to set up replication from M2 to M1, you will run into an error when you try to set gtid_slave_pos on M2 if gtid_strict_mode is enabled:

      SET GLOBAL gtid_slave_pos = '5-1234-2';
      ERROR 1948 (HY000): Specified value for @@gtid_slave_pos contains no value for replication domain 0. This conflicts with the binary log which contains GTID 0-100-135. If MASTER_GTID_POS=CURRENT_POS is used, the binlog position will override the new value of @@gtid_slave_pos
      

      This check occurs here:

      https://github.com/MariaDB/server/blob/mariadb-10.5.8/sql/sql_repl.cc#L4624

      It may make sense for this scenario to trigger an error in a simple primary-replica topology. However, in topologies with an intermediate primary server, it does not make sense for this scenario to trigger an error. The intermediate primary server is expected to have domains that the other primary server does not have.

      Perhaps we need another variable to disable this check. For example, some options might be:

      • We could create a variable called gtid_intermediate_primary that controls whether this check is performed.
      • Or we could create a variable called gtid_local_domain_ids that allows DBAs to configure domains that their primary is not expected to have, so that those domains would be ignored for this check.

      Attachments

        Issue Links

          Activity

            People

              bnestere Brandon Nesterenko
              GeoffMontee Geoff Montee (Inactive)
              Votes:
              2 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.