首页 新闻 搜索 专区 学院

Zookeeper、Kafka 出现 java.io.IOException: 远程主机强迫关闭了一个现有的连接。

0
悬赏园豆:50 [待解决问题]

最近刚搭建了Zookeeper和Kafka,学习消息队列,但是发现在Windows服务器上部署的Zookeeper、Kafka长时间运行会出现java.io.IOException: 远程主机强迫关闭了一个现有的连接。一般都是晚上跑一宿,第二天上班查看服务器,就发现这个样子了,从搭建的第一天开始,连续两天都这样,没有找到解决办法,有人遇到过没。
服务器只有一台,是Windows Server 2016

2021-10-14 08:20:29,077 [myid:] - WARN [NIOServerCxnFactory.AcceptThread:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory$AcceptThread@228] - Ignoring IOException while selecting
java.io.IOException: 远程主机强迫关闭了一个现有的连接。
at java.base/sun.nio.ch.IOUtil.drain(Native Method)
at java.base/sun.nio.ch.WEPollSelectorImpl.clearInterrupt(WEPollSelectorImpl.java:248)
at java.base/sun.nio.ch.WEPollSelectorImpl.processEvents(WEPollSelectorImpl.java:186)
at java.base/sun.nio.ch.WEPollSelectorImpl.doSelect(WEPollSelectorImpl.java:116)
at java.base/sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:129)
at java.base/sun.nio.ch.SelectorImpl.select(SelectorImpl.java:146)
at org.apache.zookeeper.server.NIOServerCnxnFactory$AcceptThread.select(NIOServerCnxnFactory.java:205)
at org.apache.zookeeper.server.NIOServerCnxnFactory$AcceptThread.run(NIOServerCnxnFactory.java:181)

ERROR [TransactionCoordinator id=0] Unexpected error during I/O (org.apache.kafka.clients.NetworkClient)
java.io.IOException: 远程主机强迫关闭了一个现有的连接。
at java.base/sun.nio.ch.IOUtil.drain(Native Method)
at java.base/sun.nio.ch.WEPollSelectorImpl.clearInterrupt(WEPollSelectorImpl.java:248)
at java.base/sun.nio.ch.WEPollSelectorImpl.processEvents(WEPollSelectorImpl.java:186)
at java.base/sun.nio.ch.WEPollSelectorImpl.doSelect(WEPollSelectorImpl.java:116)
at java.base/sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:129)
at java.base/sun.nio.ch.SelectorImpl.select(SelectorImpl.java:141)
at org.apache.kafka.common.network.Selector.select(Selector.java:869)
at org.apache.kafka.common.network.Selector.poll(Selector.java:465)
at org.apache.kafka.clients.NetworkClient.poll(NetworkClient.java:561)
at kafka.common.InterBrokerSendThread.pollOnce(InterBrokerSendThread.scala:74)
at kafka.common.InterBrokerSendThread.doWork(InterBrokerSendThread.scala:94)
at kafka.utils.ShutdownableThread.run(ShutdownableThread.scala:96)
[2021-10-14 08:19:22,350] ERROR Error occurred (kafka.network.Acceptor)

问题补充:

从启动到zookeeper出现问题是2个小时,每次都这样

衆尋的主页 衆尋 | 初学一级 | 园豆:170
提问于:2021-10-14 10:02
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册