Pulsar集成etcd集群时,初始化元数据报错

我使用的pulsar版本是2.10.1
我在使用etcd集群作为pulsar集群的配置元数据存储时,执行pulsar集群初始化命令时,报端口超出范围错误:
2022-08-23T09:46:27,408-0400 [main] INFO org.apache.pulsar.PulsarClusterMetadataSetup - Setting up cluster pulsar-cluster with metadata-store=etcd:node01:2379,node02:2379,node03:2379 configuration-metadata-store=etcd:node01:2379,node02:2379,node03:2379
2022-08-23T09:46:30,314-0400 [grpc-default-executor-0] WARN io.etcd.jetcd.resolver.IPNameResolver - Error wile getting list of servers
java.lang.IllegalArgumentException: port out of range:-1
at java.net.InetSocketAddress.checkPort(InetSocketAddress.java:143) ~[?:1.8.0_322]
at java.net.InetSocketAddress.(InetSocketAddress.java:224) ~[?:1.8.0_322]
at io.etcd.jetcd.resolver.IPNameResolver$HostAndPort.toAddressGroup(IPNameResolver.java:162) ~[io.etcd-jetcd-core-0.5.11.jar:?]
at io.etcd.jetcd.resolver.IPNameResolver.lambda$doResolve$1(IPNameResolver.java:133) ~[io.etcd-jetcd-core-0.5.11.jar:?]
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) ~[?:1.8.0_322]
at java.util.ArrayList$ArrayListSpliterator.

我执行的命令如下:
./bin/pulsar initialize-cluster-metadata
-c pulsar-cluster
-md etcd:node01:2379,node02:2379,node03:2379
-cms etcd:node01:2379,node02:2379,node03:2379
-uw http://node01:8080,node02:8080,node03:8080
-tw https://node01:8443,node02:8443,node03:8443
-ub pulsar://node01:6650,node02:6650,node03:6650
-tb pulsar+ssl://node01:6651,node02:6651,node03:6651

为什么会报 -1 端口超出范围?
我设置的端口是2379啊,有没有大佬解答一下。

能发下命令截图吗,看起来好像是笔误,报IP 格式解析错误。是不是 IP:port 格式写错了。

已回答:I encountered a port error when using pulsar to integrate etcd · Discussion #17240 · apache/pulsar · GitHub

需要注意的一点是:每一个 etcd 地址都需要 url schema,例如 http://

1 Like