开发者社区> 问答> 正文

关于客户端authentication: auth failed for user:canal问题

环境信息

canal version 1.1.4 mysql version 5.6 windows 10

问题描述

关于canaladapter客户端启动一种报错的问题,为什么还没修复:

Connected to the target VM, address: '127.0.0.1:52171', transport: 'socket' process error!com.alibaba.otter.canal.protocol.exception.CanalClientException: something goes wrong when doing authentication: auth failed for user:canal at com.alibaba.otter.canal.client.impl.SimpleCanalConnector.doConnect(SimpleCanalConnector.java:191) ~[classes/:na] at com.alibaba.otter.canal.client.impl.SimpleCanalConnector.connect(SimpleCanalConnector.java:115) ~[classes/:na] at com.alibaba.otter.canal.example.AbstractCanalClientTest.process(AbstractCanalClientTest.java:56) ~[classes/:na] at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_202] process error!com.alibaba.otter.canal.protocol.exception.CanalClientException: something goes wrong when doing authentication: auth failed for user:canal at com.alibaba.otter.canal.client.impl.SimpleCanalConnector.doConnect(SimpleCanalConnector.java:191) ~[classes/:na] at com.alibaba.otter.canal.client.impl.SimpleCanalConnector.connect(SimpleCanalConnector.java:115) ~[classes/:na] at com.alibaba.otter.canal.example.AbstractCanalClientTest.process(AbstractCanalClientTest.java:56) ~[classes/:na] at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_202]

提问145.png

步骤重现

1、直接执行canal.adapter-1.1.4.bat 报错

2、执行客户端类: SimpleCanalClientTest 报错

都是授权失败,就一个测试demo你授权什么?

实际执行情况

Ack ackBody = Ack.parseFrom(ack.getBody()); if (ackBody.getErrorCode() > 0) { throw new CanalClientException("something goes wrong when doing authentication: " + ackBody.getErrorMessage()); }

原提问者GitHub用户yangzhiwen911

展开
收起
山海行 2023-04-27 19:48:19 196 0
1 条回答
写回答
取消 提交回答
  • 服务端开启了auth认证,账号密码不对

    原回答者GitHub用户agapple

    2023-04-28 14:28:43
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
低代码开发师(初级)实战教程 立即下载
冬季实战营第三期:MySQL数据库进阶实战 立即下载
阿里巴巴DevOps 最佳实践手册 立即下载