maxwell无法从MySQL读取事件

时间:2019-09-17 17:14:04

标签: mysql docker database-replication

我正在使用maxwell v.1.22.5和MySQL v8.0.4。 Maxwell在EC2实例上的docker容器内运行,而MySQL在另一个EC2实例上运行。

我正在使用docker运行maxwell

sudo docker run -it --rm zendesk/maxwell bin/maxwell --user='maxwell' --password='XXXXXX' --host="X.X.X.X" --producer=stdout --init_position=master.000143:83923572

我给了init_position,因为它失败了,否则出现以下错误com.github.shyiko.mysql.binlog.network.ServerException: Could not find first log file name in binary log index file

使用init_position选项,出现以下错误:

BinaryLogClient - Connected to 10.11.3.221:3306 at master.000143/839235728 (sid:6379, cid:1051309)
16:53:53,235 INFO  BinlogConnectorLifecycleListener - Binlog connected.
16:53:53,336 INFO  BinlogConnectorLifecycleListener - Binlog disconnected.
16:53:53,338 INFO  TaskManager - Stopping 3 tasks
16:53:53,339 ERROR TaskManager - cause:
java.lang.RuntimeException: Couldn't find database metabase
    at com.zendesk.maxwell.replication.TableCache.processEvent(TableCache.java:26) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.replication.BinlogConnectorReplicator.getTransactionRows(BinlogConnectorReplicator.java:490) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.replication.BinlogConnectorReplicator.getRow(BinlogConnectorReplicator.java:596) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.replication.BinlogConnectorReplicator.work(BinlogConnectorReplicator.java:177) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.util.RunLoopProcess.runLoop(RunLoopProcess.java:34) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.Maxwell.startInner(Maxwell.java:222) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.Maxwell.start(Maxwell.java:156) ~[maxwell-1.22.5.jar:1.22.5]
    at com.zendesk.maxwell.Maxwell.main(Maxwell.java:243) ~[maxwell-1.22.5.jar:1.22.5]

有人可以阐明似乎确切的问题吗? PS:我在MySQL中检查了是否存在一个名为“元数据库”的数据库。另外,我还有一个maxwell实例正在监听通过简单命令行运行的MySQL主服务器,例如bin/maxwell --user='maxwell' --password='XXXXXX' --host='127.0.0.1' --producer=stdout

0 个答案:

没有答案