簡體   English   中英

MariaDB + MaxScale復制錯誤:從屬I / O線程停止,因為在嘗試選擇@master_binlog_checksum時遇到致命錯誤

[英]MariaDB + MaxScale Replication Error : The slave I/O thread stops because a fatal error is encountered when it tried to SELECT @master_binlog_checksum

我正在嘗試使用帶有MariaDB veriosn 10.0.32的MaxScale CDC設置到Kafka的實時數據流。 配置復制后,我得到以下狀態:

“從屬I / O線程停止,因為在嘗試選擇@master_binlog_checksum時遇到致命錯誤”。

以下是我的所有配置:

MariaDB-配置

server-id               = 1
#report_host            = master1
#auto_increment_increment = 2
#auto_increment_offset  = 1
log_bin                 = /var/log/mysql/mariadb-bin
log_bin_index           = /var/log/mysql/mariadb-bin.index
binlog_format           = row
binlog_row_image        = full
# not fab for performance, but safer
#sync_binlog            = 1
expire_logs_days        = 10
max_binlog_size         = 100M
# slaves
#relay_log              = /var/log/mysql/relay-bin
#relay_log_index        = /var/log/mysql/relay-bin.index
#relay_log_info_file    = /var/log/mysql/relay-bin.info
#log_slave_updates
#read_only

MaxScale配置

[server1]
type=server
address=192.168.56.102
port=3306
protocol=MariaDBBackend

[Replication]
type=service
router=binlogrouter
version_string=10.0.27-log
user=myuser
passwd=mypwd
server_id=3
#binlogdir=/var/lib/maxscale
#mariadb10-compatibility=1
router_options=binlogdir=/var/lib/maxscale,mariadb10-compatibility=1
#slave_sql_verify_checksum=1

[Replication Listener]
type=listener
service=Replication
protocol=MySQLClient
port=5308

開始復制

CHANGE MASTER TO MASTER_HOST='192.168.56.102', MASTER_PORT=5308, MASTER_USER='myuser', MASTER_PASSWORD='mypwd', MASTER_LOG_POS=328, MASTER_LOG_FILE='mariadb-bin.000018';
START SLAVE;

復制狀態

                  Master_Host: 192.168.56.102
                  Master_User: myuser
                  Master_Port: 5308
                Connect_Retry: 60
              Master_Log_File: mariadb-bin.000018
          Read_Master_Log_Pos: 328
               Relay_Log_File: mysqld-relay-bin.000002
                Relay_Log_Pos: 4
        Relay_Master_Log_File: mariadb-bin.000018
             **Slave_IO_Running: No**
            Slave_SQL_Running: Yes
              Replicate_Do_DB:
          Replicate_Ignore_DB:
           Replicate_Do_Table:
       Replicate_Ignore_Table:
      Replicate_Wild_Do_Table:
  Replicate_Wild_Ignore_Table:
                   Last_Errno: 0
                   Last_Error:
                 Skip_Counter: 0
          Exec_Master_Log_Pos: 328
              Relay_Log_Space: 248
              Until_Condition: None
               Until_Log_File:
                Until_Log_Pos: 0
           Master_SSL_Allowed: No
           Master_SSL_CA_File:
           Master_SSL_CA_Path:
              Master_SSL_Cert:
            Master_SSL_Cipher:
               Master_SSL_Key:
        Seconds_Behind_Master: NULL
Master_SSL_Verify_Server_Cert: No
                Last_IO_Errno: 1593
                Last_IO_Error: **The slave I/O thread stops because a fatal error is encountered when it tried to SELECT @master_binlog_checksum. Error:**
               Last_SQL_Errno: 0
               Last_SQL_Error:
  Replicate_Ignore_Server_Ids:
             Master_Server_Id: 0
               Master_SSL_Crl:
           Master_SSL_Crlpath:
                   Using_Gtid: No
                  Gtid_IO_Pos:

binlogrouter執行以下查詢以設置@master_binlog_checksum的值(實際復制從屬執行相同的查詢)。

SET @master_binlog_checksum = @@global.binlog_checksum

檢查它的輸出可能會解釋為什么復制不會開始。 SET查詢很可能失敗,這就是為什么后面的SELECT @master_binlog_checksum查詢返回意外結果的原因。


在這種情況下,建議在MaxScale項目下打開MariaDB Jira的錯誤報告。 這樣就排除了可能的錯誤,如果事實證明是配置問題,則可以更新文檔以更清楚地說明如何配置MaxScale。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM