dubbo使用元数据中心,zookeeper地址如果太长,会报错Failed to save service store file

3htmauhk  于 3个月前  发布在  Zookeeper
关注(0)|答案(4)|浏览(97)

dubbo:3.2.0版本
zookeeper地址使用k8s headless地址:data-zookeeper-0.zookeepers.platform.svc.cluster.local:2181,data-zookeeper-
1.zookeepers.platform.svc.cluster.local:2181,data-zookeeper-2.zookeepers.platform.svc.cluster.local:2181

报错日志
2023-05-15 14:41:14.311 [TID:N/A] [DubboSaveMetadataReport-thread-1] WARN o.a.d.m.s.z.ZookeeperMetadataReport:? - [DUBBO] Failed to save service store file, cause: File name too long, dubbo version: 3.2.0, current host: 100.64.0.4, error code: 0-12. This may be caused by , go to https://dubbo.apache.org/faq/0/12 to find instructions.
java.io.IOException: File name too long
at java.base/java.io.UnixFileSystem.createFileExclusively(Native Method)
at java.base/java.io.File.createNewFile(File.java:1035)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.doSaveProperties(AbstractMetadataReport.java:171)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.access$100(AbstractMetadataReport.java:83)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport$SaveProperties.run(AbstractMetadataReport.java:267)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
2023-05-15 14:41:14.311 [TID:N/A] [DubboSaveMetadataReport-thread-1] WARN o.a.d.m.s.z.ZookeeperMetadataReport:? - [DUBBO] Failed to save service store file, cause: File name too long, dubbo version: 3.2.0, current host: 100.64.0.4, error code: 0-12. This may be caused by , go to https://dubbo.apache.org/faq/0/12 to find instructions.
java.io.IOException: File name too long
at java.base/java.io.UnixFileSystem.createFileExclusively(Native Method)
at java.base/java.io.File.createNewFile(File.java:1035)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.doSaveProperties(AbstractMetadataReport.java:171)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.access$100(AbstractMetadataReport.java:83)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport$SaveProperties.run(AbstractMetadataReport.java:267)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
2023-05-15 14:41:14.311 [TID:N/A] [DubboSaveMetadataReport-thread-1] WARN o.a.d.m.s.z.ZookeeperMetadataReport:? - [DUBBO] Failed to save service store file, cause: File name too long, dubbo version: 3.2.0, current host: 100.64.0.4, error code: 0-12. This may be caused by , go to https://dubbo.apache.org/faq/0/12 to find instructions.
java.io.IOException: File name too long
at java.base/java.io.UnixFileSystem.createFileExclusively(Native Method)
at java.base/java.io.File.createNewFile(File.java:1035)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.doSaveProperties(AbstractMetadataReport.java:171)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport.access$100(AbstractMetadataReport.java:83)
at org.apache.dubbo.metadata.report.support.AbstractMetadataReport$SaveProperties.run(AbstractMetadataReport.java:267)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

olhwl3o2

olhwl3o22#

前缀太长了,windows会把地址前缀也算进去

wgx48brx

wgx48brx3#

如何解决?是linux报错,不是windows @aamingaa

dgtucam1

dgtucam14#

@yeeeee7 不太严格的说 在k8s 中xxx.svc.cluster.local 和xxx 是相同的 其实你可以直接去掉svc.cluster.local 后缀

相关问题