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

Poor RBR update performance with partitioned tables

Details

    Description

      This is related to the following upstream bug:

      https://bugs.mysql.com/bug.php?id=73648

      When binlog_format=ROW is set and a partitioned table is updated, the update seems to perform much slower than an equivalent update of a non-partitioned table.

      Some MTR tests have been contributed to demonstrate this problem. They are in the attached zip archive. The results were reported as the following:

      mariadb-10.1.31

      bug.test 'innodb_plugin,row' [ pass ] 114205
      bug.test_no_partition 'innodb_plugin,row' [ pass ] 22101

      bug.test 'row,xtradb' [ pass ] 429822
      bug.test_no_partition 'row,xtradb' [ pass ] 65829

      mariadb 10.2.12

      bug.test 'innodb,row' [ pass ] 161739
      bug.test_no_partition 'innodb,row' [ pass ] 28501

      mysql-5.6.39

      bug.test [ pass ] 158594
      bug.test_no_partition [ pass ] 20350

      mysql 5.7.21

      bug.test [ pass ] 37490
      bug.test_no_partition [ pass ] 26441

      MySQL 5.7 most likely performs better because of the introduction of native partitioning. Native partitioning was removed from MariaDB 10.2 during the 5.7 InnoDB merge. See MDEV-15223.

      Attachments

        Issue Links

          Activity

            Elkin Andrei Elkin added a comment -

            Sergei, hello.

            Find below is a patch header. [I had to struggle for few hours
            to clear out the mysql's patch which did not run at once through
            my error to build properly.]

            Cheers,

            Andrei

            From: andrei.elkin@pp.inet.fi
            Subject: [Commits] 37b432c1d59: MDEV-15242 Poor RBR update performance with
            partitioned tables
            To: commits@mariadb.org
            Date: Tue, 19 Jun 2018 18:26:19 +0300 (19 seconds ago)
            Reply-To: maria-developers@lists.launchpad.net

            revision-id: 37b432c1d59e66b742f97a280cae7784d85e62ec (mariadb-10.0.35-41-g37b432c1d59)
            parent(s): d2e1ed8b936a78ceeec0e64231997d7ed18a4daf
            author: Andrei Elkin
            committer: Andrei Elkin
            timestamp: 2018-06-19 18:14:47 +0300
            message:

            MDEV-15242 Poor RBR update performance with partitioned tables

            Observed and described
            partitioned engine execution time difference
            between master and slave was caused by excessive invocation
            of base_engine::rnd_init which was done also for partitions
            uninvolved into Rows-event operation.
            The bug's slave slowdown therefore scales with the number of partitions.

            Fixed with applying an upstream patch.

            References:
            ----------
            https://bugs.mysql.com/bug.php?id=73648
            Bug#25687813 REPLICATION REGRESSION WITH RBR AND PARTITIONED TABLES

            Elkin Andrei Elkin added a comment - Sergei, hello. Find below is a patch header. [I had to struggle for few hours to clear out the mysql's patch which did not run at once through my error to build properly.] Cheers, Andrei From: andrei.elkin@pp.inet.fi Subject: [Commits] 37b432c1d59: MDEV-15242 Poor RBR update performance with partitioned tables To: commits@mariadb.org Date: Tue, 19 Jun 2018 18:26:19 +0300 (19 seconds ago) Reply-To: maria-developers@lists.launchpad.net revision-id: 37b432c1d59e66b742f97a280cae7784d85e62ec (mariadb-10.0.35-41-g37b432c1d59) parent(s): d2e1ed8b936a78ceeec0e64231997d7ed18a4daf author: Andrei Elkin committer: Andrei Elkin timestamp: 2018-06-19 18:14:47 +0300 message: MDEV-15242 Poor RBR update performance with partitioned tables Observed and described partitioned engine execution time difference between master and slave was caused by excessive invocation of base_engine::rnd_init which was done also for partitions uninvolved into Rows-event operation. The bug's slave slowdown therefore scales with the number of partitions. Fixed with applying an upstream patch. References: ---------- https://bugs.mysql.com/bug.php?id=73648 Bug#25687813 REPLICATION REGRESSION WITH RBR AND PARTITIONED TABLES
            Elkin Andrei Elkin added a comment -

            The patch is pushed as 28e1f1453f1.

            Elkin Andrei Elkin added a comment - The patch is pushed as 28e1f1453f1.

            Elkin or Anyone else who might know:

            Will this be fixed in the next 10.1, which will be 10.1.35 (tentatively scheduled for 7/27/18)?

            Many thanks in advance.

            ccalender Chris Calender (Inactive) added a comment - Elkin or Anyone else who might know: Will this be fixed in the next 10.1, which will be 10.1.35 (tentatively scheduled for 7/27/18)? Many thanks in advance.

            I'mm 90% sure yes ccalender

            julien.fritsch Julien Fritsch added a comment - I'mm 90% sure yes ccalender

            People

              Elkin Andrei Elkin
              GeoffMontee Geoff Montee (Inactive)
              Votes:
              3 Vote for this issue
              Watchers:
              9 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.