Skip to content

[Bug] Rocketmq namesrv解析网卡v6地址存在问题 #9987

@tcxdgit

Description

@tcxdgit

Before Creating the Bug Report

  • I found a bug, not just asking a question, which should be created in GitHub Discussions.

  • I have searched the GitHub Issues and GitHub Discussions of this repository and believe that this is not a duplicate.

  • I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.

Runtime platform environment

纯单栈v6环境启动运行namesrv

RocketMQ version

5.1.3

JDK Version

1.8

Describe the Bug

v6环境部署namesrv组件。日志发现解析v6地址存在问题

Steps to Reproduce

使用bin/mqnamesrv -c /root/rocketmq-5.1.3-1/conf/namesrv.conf启动namesrv组件。发现日志报错,类似v6地址解析异常。后续broker无法注册namesrv。

Image Image

What Did You Expect to See?

应该解析得到[202:202:0:0:0:0:81:1811]:9876 这样的地址。通过 ping6 202:202:0:0:0:0:81:1811和 nc -vz -6 202:202:0:0:0:0:81:1811 9876都可以连通。

What Did You See Instead?

createChannel: begin to connect remote host[[202:202:0:0:0:0:81:1811%enp1s0]:9876]
java.net.UnknownHostException: [202: invalid IPv6 address literal

Additional Context

no

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions