开发者社区> 问答> 正文

rocketmq启动broker报错

做了多Master多Slave模式(同步)的集群,不过启动Master的broker的时候,没有报任何错误,但是当启动Slave的broker的时候报如下的错误:org.apache.rocketmq.remoting.exception.RemotingConnectException: connect to rocketmq-nameserver1:9876 failed at org.apache.rocketmq.remoting.netty.NettyRemotingClient.invokeSync(NettyRemotingClient.java:392) ~[rocketmq-remoting-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.out.BrokerOuterAPI.unregisterBroker(BrokerOuterAPI.java:248) ~[rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.out.BrokerOuterAPI.unregisterBrokerAll(BrokerOuterAPI.java:225) ~[rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerController.unregisterBrokerAll(BrokerController.java:814) [rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerController.shutdown(BrokerController.java:757) [rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerStartup$1.run(BrokerStartup.java:235) [rocketmq-broker-4.4.0.jar:4.4.0] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_121] 2020-03-16 17:02:54 WARN ShutdownHook - unregisterBroker Exception, rocketmq-nameserver2:9876 org.apache.rocketmq.remoting.exception.RemotingConnectException: connect to rocketmq-nameserver2:9876 failed at org.apache.rocketmq.remoting.netty.NettyRemotingClient.invokeSync(NettyRemotingClient.java:392) ~[rocketmq-remoting-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.out.BrokerOuterAPI.unregisterBroker(BrokerOuterAPI.java:248) ~[rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.out.BrokerOuterAPI.unregisterBrokerAll(BrokerOuterAPI.java:225) ~[rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerController.unregisterBrokerAll(BrokerController.java:814) [rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerController.shutdown(BrokerController.java:757) [rocketmq-broker-4.4.0.jar:4.4.0] at org.apache.rocketmq.broker.BrokerStartup$1.run(BrokerStartup.java:235) [rocketmq-broker-4.4.0.jar:4.4.0] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_121]

请问大佬们知道原因吗

展开
收起
游客yz77mnfzund6g 2020-03-16 17:27:07 4154 0
2 条回答
写回答
取消 提交回答
  • 我也遇到这个问题,大哥你后来解决了吗

    2020-09-04 13:21:22
    赞同 展开评论 打赏
  • 1,检查rocketmq.config.namesrvAddr是否已经配置 2,文件位于rocketmq-externals/rocketmq-console/src/main/resources下面 修改 application.properties rocketmq.config.namesrvAddr=127.0.0.1:9876 rocketmq.config.isVIPChannel=false

    完事重新打包 mvn clean package -Dmaven.test.skip=true

    运行

    java -jar rocketmq-console-ng-1.0.0.jar

     

    2020-03-22 17:01:00
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
RocketMQ Client-GO 介绍 立即下载
RocketMQ Prometheus Exporter 打造定制化 DevOps 平台 立即下载
基于 RocketMQ Prometheus Exporter 打造定制化 DevOps 平台 立即下载