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

Slave unable to sync with master

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.6.11
    • 10.6
    • Backup, Replication
    • None
    • RedHat 8

    Description

      Step to reproduce:

      1. make a full backup on master node using mariabackup
      2. copy the backup to slave node
      3. on slave node, restore the backup in /var/lib/mysql, then start mariadb service
      4. set CHANGE MASTER to master node, then start slave

      problems:
      when replication just start, it does replicate from master, but quickly, in "show slave status", I got:

                          Last_Errno: 1062
                          Last_Error: Could not execute Write_rows_v1 event on table InboundBankStatements.MT940Transactions; Duplicate entry 'DK3852950010031982-2023-11-1-DKK' for key 'AccountNrYearStatementSequenceCurrency', Error_code: 1062; handler error HA_ERR_FOUND_DUPP_KEY; the event's master log mysql-bin.008366, end_log_pos 81077987
      

      after "set global SQL_SLAVE_SKIP_COUNTER = 1;", new error appeared:

                          Last_Errno: 1452
                          Last_Error: Could not execute Write_rows_v1 event on table InboundBankStatements.MT940Balances; Cannot add or update a child row: a foreign key constraint fails (`InboundBankStatements`.`MT940Balances`, CONSTRAINT `_balance_trx_fk1` FOREIGN KEY (`TrxId`) REFERENCES `MT940Transactions` (`Id`) ON DELETE CASCADE), Error_code: 1452; handler error HA_ERR_NO_REFERENCED_ROW; the event's master log mysql-bin.008366, end_log_pos 81078709
      

      After downgraded MariaDB on slave node to 10.6.10, then repeat the steps above, the replication worked nicely.

      Attachments

        Activity

          People

            angelique.sklavounos Angelique Sklavounos (Inactive)
            kevinwang1975 Kevin Wang
            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.