Reply
New Contributor
Posts: 7
Registered: ‎06-10-2014

kafka topics failed UnknownHostException

I installed and add Kafka service through Cloudera Manager, which looks fine.

But when I try to test it like list topics, it gave error like:

./kafka-topics.sh --list --zookeeper localhost:2181

 

java.net.UnknownHostException: opt

at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:178)

 

I dont where the host 'opt' come from?

Cloudera Employee
Posts: 461
Registered: ‎08-11-2014

Re: kafka topics failed UnknownHostException

The command should just be "kafka-topics". Are you running some local custom script? that's what your CLI shows, and maybe it has some reference to 'opt'. 

Highlighted
New Contributor
Posts: 7
Registered: ‎06-10-2014

Re: kafka topics failed UnknownHostException

kafka-topics command is under $KAFKA_HOME/bin.

It calls kafka-topics.sh, which is under $KAFKA_HOME/lib/kafka/bin.

Both basically are same thing.

Also kafka-topics gave same error.

Announcements

Currently incubating in Cloudera Labs:

Envelope
HTrace
Ibis
Impyla
Livy
Oryx
Phoenix
Spark Runner for Beam SDK
Time Series for Spark
YCSB