开发者社区> 问答> 正文

canal-1.1.1 tcp模式启动,日志正常, client没收到消息

canal.log: 2018-11-13 13:26:09.610 [main] ERROR com.alibaba.druid.pool.DruidDataSource - testWhileIdle is true, validationQuery not set 2018-11-13 13:26:09.641 [main] INFO com.alibaba.druid.pool.DruidDataSource - {dataSource-1} inited 2018-11-13 13:26:09.929 [main] INFO c.a.o.c.p.inbound.mysql.tsdb.DefaultTableMetaTSDBFactory - example init TableMetaTSDB with classpath:spring/tsdb/h2-tsdb.xml 2018-11-13 13:26:09.932 [main] INFO com.alibaba.otter.canal.prometheus.CanalInstanceExports - Successfully register metrics for instance example. 2018-11-13 13:26:09.932 [main] INFO com.alibaba.otter.canal.prometheus.PrometheusService - Register metrics for destination example. 2018-11-13 13:26:09.981 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.a.o.c.p.inbound.mysql.rds.RdsBinlogEventParserProxy - start heart beat.... 2018-11-13 13:26:10.004 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.027 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.033 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.070 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.071 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.071 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.124 [main] INFO c.a.otter.canal.server.embedded.CanalServerWithEmbedded - start CanalInstances[example] successfully 2018-11-13 13:26:10.174 [destination = example , address = /10.0.0.61:3306 , EventParser] WARN c.a.o.c.p.inbound.mysql.rds.RdsBinlogEventParserProxy - prepare to find start position just show master status 2018-11-13 13:26:10.175 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - disConnect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.176 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.177 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.208 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.215 [main] INFO com.alibaba.otter.canal.deployer.CanalLauncher - ## the canal server is running now ...... 2018-11-13 13:26:10.220 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.a.otter.canal.parse.inbound.mysql.MysqlConnection - COM_BINLOG_DUMP with position:BinlogDumpCommandPacket[binlogPosition=4,slaveServerId=1234,binlogFileName=mysql-bin.000004,command=18] 2018-11-13 13:26:10.249 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO com.taobao.tddl.dbsync.binlog.LogEvent - common_header_len= 19, number_of_event_types= 35

example.log: 2018-11-13 13:26:08.708 [main] INFO o.s.context.support.ClassPathXmlApplicationContext - Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@10dba097: startup date [Tue Nov 13 13:26:08 CST 2018]; root of context hierarchy 2018-11-13 13:26:08.751 [main] INFO o.s.beans.factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [spring/file-instance.xml] 2018-11-13 13:26:08.891 [main] INFO o.s.beans.factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [spring/base-instance.xml] 2018-11-13 13:26:09.038 [main] INFO c.a.o.c.i.spring.support.PropertyPlaceholderConfigurer - Loading properties file from class path resource [canal.properties] 2018-11-13 13:26:09.039 [main] INFO c.a.o.c.i.spring.support.PropertyPlaceholderConfigurer - Loading properties file from class path resource [example/instance.properties] 2018-11-13 13:26:09.057 [main] INFO o.s.beans.factory.support.DefaultListableBeanFactory - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@68999068: defining beans [com.alibaba.otter.canal.instance.spring.support.PropertyPlaceholderConfigurer#0,socketAddressEditor,org.springframework.beans.factory.config.CustomEditorConfigurer#0,baseEventParser,instance,alarmHandler,metaManager,eventStore,eventSink,eventParser]; root of factory hierarchy 2018-11-13 13:26:09.201 [main] WARN o.s.beans.GenericTypeAwarePropertyDescriptor - Invalid JavaBean property 'connectionCharset' being accessed! Ambiguous write methods found next to actually used [public void com.alibaba.otter.canal.parse.inbound.mysql.AbstractMysqlEventParser.setConnectionCharset(java.nio.charset.Charset)]: [public void com.alibaba.otter.canal.parse.inbound.mysql.AbstractMysqlEventParser.setConnectionCharset(java.lang.String)] 2018-11-13 13:26:09.235 [main] INFO o.s.context.support.ClassPathXmlApplicationContext - Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@13b13b5d: startup date [Tue Nov 13 13:26:09 CST 2018]; root of context hierarchy 2018-11-13 13:26:09.237 [main] INFO o.s.beans.factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [spring/tsdb/h2-tsdb.xml] 2018-11-13 13:26:09.317 [main] INFO c.a.o.c.i.spring.support.PropertyPlaceholderConfigurer - Loading properties file from class path resource [canal.properties] 2018-11-13 13:26:09.318 [main] INFO c.a.o.c.i.spring.support.PropertyPlaceholderConfigurer - Loading properties file from class path resource [example/instance.properties] 2018-11-13 13:26:09.326 [main] INFO o.s.beans.factory.support.DefaultListableBeanFactory - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@4e7912d8: defining beans [com.alibaba.otter.canal.instance.spring.support.PropertyPlaceholderConfigurer#0,tableMetaTSDB,dataSource,sqlMapClient,metaHistoryDAO,metaSnapshotDAO]; root of factory hierarchy 2018-11-13 13:26:09.610 [main] ERROR com.alibaba.druid.pool.DruidDataSource - testWhileIdle is true, validationQuery not set 2018-11-13 13:26:09.641 [main] INFO com.alibaba.druid.pool.DruidDataSource - {dataSource-1} inited 2018-11-13 13:26:09.929 [main] INFO c.a.o.c.p.inbound.mysql.tsdb.DefaultTableMetaTSDBFactory - example init TableMetaTSDB with classpath:spring/tsdb/h2-tsdb.xml 2018-11-13 13:26:09.932 [main] INFO com.alibaba.otter.canal.prometheus.CanalInstanceExports - Successfully register metrics for instance example. 2018-11-13 13:26:09.932 [main] INFO com.alibaba.otter.canal.prometheus.PrometheusService - Register metrics for destination example. 2018-11-13 13:26:09.932 [main] INFO c.a.otter.canal.instance.spring.CanalInstanceWithSpring - start CannalInstance for 1-example 2018-11-13 13:26:09.981 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.a.o.c.p.inbound.mysql.rds.RdsBinlogEventParserProxy - start heart beat.... 2018-11-13 13:26:10.004 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.027 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.033 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.070 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.071 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.071 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.123 [main] INFO c.a.otter.canal.instance.core.AbstractCanalInstance - subscribe filter change to ... 2018-11-13 13:26:10.124 [main] INFO c.a.otter.canal.instance.core.AbstractCanalInstance - start successful.... 2018-11-13 13:26:10.124 [main] INFO c.a.otter.canal.server.embedded.CanalServerWithEmbedded - start CanalInstances[example] successfully 2018-11-13 13:26:10.174 [destination = example , address = /10.0.0.61:3306 , EventParser] WARN c.a.o.c.p.inbound.mysql.rds.RdsBinlogEventParserProxy - prepare to find start position just show master status 2018-11-13 13:26:10.175 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - disConnect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.176 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - connect MysqlConnection to /10.0.0.61:3306... 2018-11-13 13:26:10.177 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - handshake initialization packet received, prepare the client authentication packet to send 2018-11-13 13:26:10.208 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.alibaba.otter.canal.parse.driver.mysql.MysqlConnector - client authentication packet is sent out. 2018-11-13 13:26:10.220 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO c.a.otter.canal.parse.inbound.mysql.MysqlConnection - COM_BINLOG_DUMP with position:BinlogDumpCommandPacket[binlogPosition=4,slaveServerId=1234,binlogFileName=mysql-bin.000004,command=18] 2018-11-13 13:26:10.249 [destination = example , address = /10.0.0.61:3306 , EventParser] INFO com.taobao.tddl.dbsync.binlog.LogEvent - common_header_len= 19, number_of_event_types= 35

原提问者GitHub用户Czjcunzhang

展开
收起
Java工程师 2023-05-08 17:52:04 143 0
1 条回答
写回答
取消 提交回答
  • 解决了, 虚拟机 CPU核数给了1核, canal估计要至少2核才能跑起来 修改canal.properties文件中的 canal.instance.parser.parallel 属性 改为 false就可以了

    原回答者GitHub用户kaibi12

    2023-05-09 18:44:12
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
PostgresChina2018_赖思超_PostgreSQL10_hash索引的WAL日志修改版final 立即下载
Kubernetes下日志实时采集、存储与计算实践 立即下载
日志数据采集与分析对接 立即下载