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

mysqldump wipes off pre-existing gtid slave state

Details

    Description

      Created by mysqldump --gtid backup script removes any former value of
      @@global.gtid_slave.pos because the script would execute

         set @@global.gtid_slave_pos = "gtid-state-of-the-donor-server"
      
      

      and obviously discard any former value.
      Such behavior is historical and reflects the original intention to provide support for the whole
      state backup.

      Thus an automatic recomputation of the slave gtid state for the partial backup has not been provided.
      It can be done with improving on mysqldump to make it compose a new value as an union of the being backed up state
      and @@global.gtid_slave_pos of the target server.

      Attachments

        Issue Links

          Activity

            Elkin Andrei Elkin created issue -
            Elkin Andrei Elkin made changes -
            Field Original Value New Value
            Elkin Andrei Elkin made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            Elkin Andrei Elkin added a comment -

            This is covered in bb-10.5-andrei.

            Elkin Andrei Elkin added a comment - This is covered in bb-10.5-andrei.
            Elkin Andrei Elkin made changes -
            Assignee Andrei Elkin [ elkin ] Brandon Nesterenko [ JIRAUSER48702 ]
            Status In Progress [ 3 ] In Review [ 10002 ]
            knielsen Kristian Nielsen added a comment - - edited

            This change is not appropriate since it breaks backwards compatibility. I will send a review of the patch to the mailing list with comments.

            UPDATE: Review here: https://lists.mariadb.org/hyperkitty/list/developers@lists.mariadb.org/thread/PQABGTGT4OX7DNFHVMR4T52RXE2ANCGT/

            knielsen Kristian Nielsen added a comment - - edited This change is not appropriate since it breaks backwards compatibility. I will send a review of the patch to the mailing list with comments. UPDATE: Review here: https://lists.mariadb.org/hyperkitty/list/developers@lists.mariadb.org/thread/PQABGTGT4OX7DNFHVMR4T52RXE2ANCGT/
            Elkin Andrei Elkin made changes -
            Assignee Brandon Nesterenko [ JIRAUSER48702 ] Andrei Elkin [ elkin ]
            Elkin Andrei Elkin added a comment - - edited

            In a mail thread the initial idea of unconditional concatenation has been refined to do so only when a new value of master-data,dump-slave options say so.

            Elkin Andrei Elkin added a comment - - edited In a mail thread the initial idea of unconditional concatenation has been refined to do so only when a new value of master-data,dump-slave options say so.
            Elkin Andrei Elkin made changes -
            Status In Review [ 10002 ] Stalled [ 10000 ]
            Elkin Andrei Elkin made changes -
            Affects Version/s 10.5 [ 23123 ]
            Affects Version/s 10.6 [ 24028 ]
            Affects Version/s 10.11 [ 27614 ]
            Affects Version/s 11.1 [ 28549 ]
            Affects Version/s 11.2 [ 28603 ]
            Affects Version/s 11.4 [ 29301 ]
            Elkin Andrei Elkin made changes -
            Fix Version/s 10.5 [ 23123 ]
            Fix Version/s 10.6 [ 24028 ]
            Fix Version/s 10.11 [ 27614 ]
            Fix Version/s 11.1 [ 28549 ]
            Fix Version/s 11.2 [ 28603 ]
            Fix Version/s 11.4 [ 29301 ]
            Elkin Andrei Elkin made changes -
            Issue Type Bug [ 1 ] Task [ 3 ]
            Elkin Andrei Elkin made changes -
            Description Created by mysqldump --gtid backup script removes any former value of
            @@global.gtid_slave.pos because the script would execute
               set @@global.gtid_slave_pos = "gtid-state-of-the-donor-server"
            and obviously discard any former value.
            Such behavior hurts partial backup restore.

            This can fixed by mysqldump to compose a new value as an union of the being backed up state
            and @@global.gtid_slave_pos of the target server.
            Created by {{mysqldump \--gtid}} backup script removes any former value of
            {{@@global.gtid_slave.pos}} because the script would execute

            {code:java}
               set @@global.gtid_slave_pos = "gtid-state-of-the-donor-server"

            {code}
            and obviously discard any former value.
            Such behavior is historical and reflects the original intention to provide support for the whole
            state backup.

            Thus an automatic recomputation of the slave gtid state for the partial backup has not been provided.
            It can be done with improving on mysqldump to make it compose a new value as an union of the being backed up state
            and {{@@global.gtid_slave_pos}} of the target server.
            Elkin Andrei Elkin made changes -
            Fix Version/s 11.7 [ 29815 ]
            serg Sergei Golubchik made changes -
            Fix Version/s 11.8 [ 29921 ]
            Fix Version/s 11.7 [ 29815 ]
            serg Sergei Golubchik made changes -
            Fix Version/s 11.8 [ 29921 ]

            People

              Elkin Andrei Elkin
              Elkin Andrei Elkin
              Votes:
              0 Vote for this issue
              Watchers:
              4 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.