Hello,
I am trying to setup the Kafka input in Logstash but something is not working right. Any help would be appreciated. Thanks in advance.
Error Message on Server 2 in logstash.log
{:timestamp=>"2016-03-18T10:29:52.877000-0500", :message=>"kafka client threw exception, restarting", :exception=>#<KafkaError: Got ZkException: Unable to connect to zookeeper server within timeout: 6000>, :level=>:warn}
My setup is like this:
Server 1
- logstash 2.2.2-1
- Kafka 2.11-0.9.0.1
input {
udp {
port => 5544
type => "cisco-asa"
}
}
output {
kafka {
topic_id => "test"
}
}
Server 2
- logstash 2.2.2-1
input {
kafka {
zk_connect => "Server1:2181"
topic_id => "test"
}
}
- For zk_connect option on Server 2 I've tried using IP address and hostname of Server 1but both display same error above
- Confirmed test topic is in Kafka
/opt/kafka_2.11-0.9.0.1/bin/kafka-topics.sh --list --zookeeper localhost:2181
test - Confirmed that Server 1 is listening on port 2181
- Confirmed UDP input is being sent to Kafka test topic - /opt/kafka_2.11-0.9.0.1/bin/kafka-console-consumer.sh --zookeeper localhost:2181 --topic test --from-beginning
- Zookeeper properties has maxClientCnxns=0