Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Unable to connect Zookeeper - posting with error message

Unable to connect Zookeeper - posting with error message

New Contributor

Hello, I am using virtualbox and unable to connect zookeeper from local system to virtual box and here is the error.

Error

2016-07-22 18:35:47,890 WARN zookeeper.RecoverableZooKeeper - Possibly transient ZooKeeper, quorum=127.0.0.1:2181, exception=org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /hbase-unsecure/hbaseid

2016-07-22 18:35:49,890 WARN zookeeper.ClientCnxn - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect java.net.ConnectException: Connection refused: no further information at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717) at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068)

2 REPLIES 2

Re: Unable to connect Zookeeper - posting with error message

@Anand Bisht

Try using vm hostname instead of ip address on the configs.

Re: Unable to connect Zookeeper - posting with error message

@Anand Bisht

You need to add a forwarding rule on your sandbox VM. While in Oracle VM VirtualBox Manager, right-click on the sandbox and select Settings then go to Network, click on Port Forwarding and add a rule let's call it Zookeeper with Protocol TCP, HostIP 127.0.0.1, HostPort 2181, GuestPort 2181 (or a port that is available, in case 2181 is not), click OK, OK. I don't think you have to restart the VM, even the VM is running, it should work.

If this response addressed your issue, please vote and accept it as the best answer.