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

replicate-do filters cause errors when creating filtered-out tables on master with syntax unsupported on slave

    XMLWordPrintable

Details

    Description

      When the spider engine is installed on the master but not on the slave, and replication is filtered with replicate-do-table, DDL on tables excluded by the filter will cause a replication error, so:

      Install spider engine on master

      source /usr/share/mysql/install_spider.sql
      show master status;
      

      configure slave

      change master to <the master>;
      replicate-do-table=test.r1;
      start slave;
      show slave status\G
      

      slave status

                   Slave_IO_Running: Yes
                  Slave_SQL_Running: Yes
       
                 Replicate_Do_Table: test.r1
       
                     Last_IO_Errno: 0
                      Last_IO_Error:
                     Last_SQL_Errno: 0
                     Last_SQL_Error:
       
            Slave_SQL_Running_State: Slave has read all relay log; waiting for the slave I/O thread to update it
      

      create a spider table on the master that should not be replicated on the slave

      CREATE TABLE `not_r1` (
        `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
        PRIMARY KEY (`id`)
      ) ENGINE=SPIDER COMMENT='table "not_r1", database "test", port "3306", host "10.0.0.181", user "spider", password "spider"'
      

      slave status

                   Slave_IO_Running: Yes
                  Slave_SQL_Running: No
       
                 Replicate_Do_Table: test.r1
       
                      Last_IO_Errno: 0
                      Last_IO_Error:
                     Last_SQL_Errno: 1286
                     Last_SQL_Error: Error 'Unknown storage engine 'spider'' on query. Default database: 'test'. Query: 'create table not_r1(
        `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
        PRIMARY KEY (`id`)
      ) ENGINE=spider
      COMMENT 'table "not_r1", database "test", port "3306", host "10.0.0.181", user "spider", password "spider"''
       
            Slave_SQL_Running_State:
      

      Attachments

        Issue Links

          Activity

            People

              sachin.setiya.007 Sachin Setiya (Inactive)
              juan.vera Juan
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

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