CommencerCommencer gratuitement

Error on start

When working with Kafka, you've tried many iterations while trying to determine the best configuration for your cluster. After many iterations, you suddenly see the error message below:

WARN Session 0x0 for server localhost/127.0.0.1:2181, Closing socket connection. 
Attempting reconnect except it is a SessionExpiredException. (org.apache.zookeeper.ClientCnxn)
java.net.ConnectException: Connection refused
    at java.base/sun.nio.ch.Net.pollConnect(Native Method)
    at java.base/sun.nio.ch.Net.pollConnectNow(Unknown Source)
    at java.base/sun.nio.ch.SocketChannelImpl.finishConnect(Unknown Source)
    at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:344)
    at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1289)

You receive the error above after trying to start the Kafka service with bin/kafka-server-start.sh config/server.properties. Which of the following is the likely problem?

Cet exercice fait partie du cours

Introduction to Apache Kafka

Afficher le cours

Exercice interactif pratique

Passez de la théorie à la pratique avec l’un de nos exercices interactifs

Commencer l’exercice