Support Questions
Find answers, ask questions, and share your expertise

zookeeper + Unable to connect to zookeeper server within timeout: 30000

Highlighted

zookeeper + Unable to connect to zookeeper server within timeout: 30000

we have 3 zookeeper and kafka machines in the cluster ( HDP version 2.6.4 , ) only on the first machine we have a problem with the first zookeeper server as we can see down ,

 

we also check the port 2181 is ok and also the disable of firewall and iptables

we checked the zookeeper logs and we not found special problem

we not understand what is the problem

 

/usr/hdp/current/kafka-broker/bin/kafka-topics.sh --zookeeper localhost:2181 --describe
[2019-12-07 18:47:40,639] WARN Client session timed out, have not heard from server in 30000ms for sessionid 0x0 (org.apache.zookeeper.ClientCnxn)
Exception in thread "main" org.I0Itec.zkclient.exception.ZkTimeoutException: Unable to connect to zookeeper server within timeout: 30000
        at org.I0Itec.zkclient.ZkClient.connect(ZkClient.java:1232)
        at org.I0Itec.zkclient.ZkClient.<init>(ZkClient.java:156)
        at org.I0Itec.zkclient.ZkClient.<init>(ZkClient.java:130)
        at kafka.utils.ZkUtils$.createZkClientAndConnection(ZkUtils.scala:76)
        at kafka.utils.ZkUtils$.apply(ZkUtils.scala:58)
        at kafka.admin.TopicCommand$.main(TopicCommand.scala:53)
        at kafka.admin.TopicCommand.main(TopicCommand.scala)


we also get ( instead connected ! ) 

${ZOOKEEPER_HOME}/bin/zkCli.sh Connecting to localhost:2181 Welcome to ZooKeeper! JLine support is enabled [zk: localhost:2181(CONNECTING) 0]

 

Michael-Bronson