Uploaded image for project: 'MariaDB MaxScale'
  1. MariaDB MaxScale
  2. MXS-3423

MaxScale binlogrouter(binlog server) fail-over error

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Won't Do
    • 2.4.9
    • N/A
    • binlogrouter
    • None
    • Centos7, mariadb10.4.12

    Description

      If I set binlogrouter, fail-over doesn't work properly Please give me an answer!

      servers:

      server1(master) : 192.168.56.101
      server2(slave1) : 192.168.56.102
      server3(slave2) : 192.168.56.103
      

      maxscale.cnf :

      [server1]
      type=server
      address=192.168.56.101
      port=3306
      protocol=mariadbbackend
       
      [server2]
      type=server
      address=192.168.56.102
      port=3306
      protocol=mariadbbackend
       
      [server3]
      type=server
      address=192.168.56.103
      port=3306
      protocol=mariadbbackend
       
      [MariaDB-Monitor]
      type=monitor
      module=mariadbmon
      servers=server1,server2,server3
      user=user
      password=pass
      monitor_interval=2000
      auto_failover=true
      auto_rejoin=true
      enforce_read_only_slaves=on
       
      [Replication]
      type=service
      router=binlogrouter
      user=dbadmin
      password=tprPdlfemdDBA1#
      server_id=1
      #master_id=101
      mariadb10-compatibility=1
      version_string=10.4.12-log
      binlogdir=/data/DBSpace/BINLOG/
      mariadb10_master_gtid=1
       
      [Replication-Listener]
      type=listener
      service=Replication
      protocol=MariaDBClient
      port=3390
      

      1.binlogrouter > master Replicaion setting

      change master to master_host ='192.168.56.101', master_port=3306, master_user='user', master_password='pass', master_log_file='bin-log.000001', master_log_pos=4;
       
      Slave_IO_State: Binlog Dump
                        Master_Host: 192.168.56.101
                        Master_User: user
                        Master_Port: 3306
                      Connect_Retry: 60
                    Master_Log_File: bin-log.000009
                Read_Master_Log_Pos: 340
                     Relay_Log_File: bin-log.000009
                      Relay_Log_Pos: 340
              Relay_Master_Log_File: bin-log.000009
                   Slave_IO_Running: Yes
                  Slave_SQL_Running: Yes
      

      2. Slave1,2 > binlogrouter GTID replicaion setting

      slave1 > change master to master_host='192.168.56.10', master_port=3306, master_user='user', master_password='pass', master_use_gtid=slave_pos;
       
      Slave_IO_State:
                         Master_Host: 192.168.56.10
                         Master_User: user
                         Master_Port: 3390
                       Connect_Retry: 60
                     Master_Log_File: bin-log.000009
                 Read_Master_Log_Pos: 340
                      Relay_Log_File: relay-log.000002
                       Relay_Log_Pos: 637
               Relay_Master_Log_File: bin-log.000009
                    Slave_IO_Running: Yes
                   Slave_SQL_Running: Yes
       
      slave2 > change master to master_host='192.168.56.10', master_port=3306, master_user='user', master_password='pass', master_use_gtid=slave_pos;
       
      Slave_IO_State:
                         Master_Host: 192.168.56.10
                         Master_User: user
                         Master_Port: 3390
                       Connect_Retry: 60
                     Master_Log_File: bin-log.000009
                 Read_Master_Log_Pos: 340
                      Relay_Log_File: relay-log.000002
                       Relay_Log_Pos: 637
               Relay_Master_Log_File: bin-log.000009
                    Slave_IO_Running: Yes
                   Slave_SQL_Running: Yes
      

      3.binlogrouter > master GTID Replicaion setting

      binlogrouter> change master to master_host='192.168.56.101', master_port=3306, master_user='user', master_password='pass', master_use_gtid=slave_pos;
       
      Slave_IO_State: Binlog Dump
                        Master_Host: 192.168.56.101
                        Master_User: user
                        Master_Port: 3306
                      Connect_Retry: 60
                    Master_Log_File: bin-log.000009
                Read_Master_Log_Pos: 340
                     Relay_Log_File: bin-log.000009
                      Relay_Log_Pos: 340
              Relay_Master_Log_File: bin-log.000009
                   Slave_IO_Running: Yes
                  Slave_SQL_Running: Yes
      

      4. maxctrl list server

      maxctrl list servers
      ┌─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ Server                                │ Address        │ Port │ Connections │ State                             │ GTID     │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ binlog_router_master_host_Replication │ _none_         │ 3360 │ 1           │ Running                           │          │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server1                               │ 192.168.56.101 │ 3306 │ 0           │ Master, Running                   │ 0-101-60 │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server2                               │ 192.168.56.102 │ 3306 │ 0           │ Slave of External Server, Running │ 0-101-60 │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server3                               │ 192.168.56.103 │ 3306 │ 0           │ Slave of External Server, Running │ 0-101-60 │
      └─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      

      5. master down

      ┌─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ Server                                │ Address        │ Port │ Connections │ State                             │ GTID     │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ binlog_router_master_host_Replication │ _none_         │ 3306 │ 0           │ Running                           │          │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server1                               │ 192.168.56.101 │ 3306 │ 0           │ Down                              │ 0-101-60 │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server2                               │ 192.168.56.102 │ 3306 │ 0           │ Slave of External Server, Running │ 0-101-60 │
      ├─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      │ server3                               │ 192.168.56.103 │ 3306 │ 0           │ Slave of External Server, Running │ 0-101-60 │
      └─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
      

      Master doesn't convert. Is there anything I set wrong?

      Attachments

        Activity

          People

            Unassigned Unassigned
            cheon cheonjinho
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.