danielqsj / kafka_exporter

Kafka exporter for Prometheus
Apache License 2.0
2.1k stars 602 forks source link

kafka_exporter start error timeout,Unexpected ApiKeys id `18`, it should be between `0` and `16` (inclusive) #329

Open wangchao732 opened 1 year ago

wangchao732 commented 1 year ago

kafka version: kafka_2.11-0.9.0-kafka-2.0.2.jar

exporter error info:

F0829 15:27:55.362877 5184 kafka_exporter.go:893] Error Init Kafka Client: kafka: client has run out of available brokers to talk to: read tcp 192.168.xx.xxx:44421->192.168.xxx.xxx:9092: i/o timeout

kafka server error log:

2022-08-29 15:30:54,903 ERROR kafka.network.Processor: Closing socket for 192.168.xxx.xxx:9092-192.168.xxx.xxx:41930 because of error kafka.network.InvalidRequestException: Error getting request for apiKey: 18 and apiVersion: 2 at kafka.network.RequestChannel$Request.liftedTree2$1(RequestChannel.scala:93) at kafka.network.RequestChannel$Request.(RequestChannel.scala:90) at kafka.network.Processor$$anonfun$processCompletedReceives$1.apply(SocketServer.scala:488) at kafka.network.Processor$$anonfun$processCompletedReceives$1.apply(SocketServer.scala:483) at scala.collection.Iterator$class.foreach(Iterator.scala:742) at scala.collection.AbstractIterator.foreach(Iterator.scala:1194) at scala.collection.IterableLike$class.foreach(IterableLike.scala:72) at scala.collection.AbstractIterable.foreach(Iterable.scala:54) at kafka.network.Processor.processCompletedReceives(SocketServer.scala:483) at kafka.network.Processor.run(SocketServer.scala:413) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.IllegalArgumentException: Unexpected ApiKeys id 18, it should be between 0 and 16 (inclusive) at org.apache.kafka.common.protocol.ApiKeys.forId(ApiKeys.java:69) at org.apache.kafka.common.requests.AbstractRequest.getRequest(AbstractRequest.java:39) at kafka.network.RequestChannel$Request.liftedTree2$1(RequestChannel.scala:90) ... 10 more