You misspelled hbase.zookeeper.quorum (dot at the end)
config.set("hbase.zookeeper.quorum.", "10.219.47.22");
Best regards,
Vladimir Rodionov
Principal Platform Engineer
Carrier IQ, www.carrieriq.com
e-mail: [email protected]
________________________________________
From: yogeshgupta [[email protected]]
Sent: Friday, November 15, 2013 4:15 AM
To: [email protected]
Subject: Unable to connect to remote hbase from java client program
Hi I am trying to connect to hbase in a remote machine from my java program.
But I am getting connection refused error. On looking at the error I think
it is trying to connect to my localhost instead of the remote machine.
My configuration is like-
Configuration config = HBaseConfiguration.create();
config.set("hbase.zookeeper.quorum.", "10.219.47.22");
config.set("hbase.zookeeper.property.clientPort", "2180");
I am getting the following error-
13/11/15 17:35:08 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(Unknown Source)
at
org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350)
at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068)
13/11/15 17:35:08 INFO zookeeper.ClientCnxn: Opening socket connection to
server 127.0.0.1/127.0.0.1:2180. Will not attempt to authenticate using SASL
(unknown error)
13/11/15 17:35:08 WARN zookeeper.RecoverableZooKeeper: Possibly transient
ZooKeeper exception:
org.apache.zookeeper.KeeperException$ConnectionLossException:
KeeperErrorCode = ConnectionLoss for /hbase/master
13/11/15 17:35:08 INFO util.RetryCounter: The 1 times to retry after
sleeping 2000 ms
--
View this message in context:
http://apache-hbase.679495.n3.nabble.com/Unable-to-connect-to-remote-hbase-from-java-client-program-tp4052843.html
Sent from the HBase User mailing list archive at Nabble.com.
Confidentiality Notice: The information contained in this message, including
any attachments hereto, may be confidential and is intended to be read only by
the individual or entity to whom this message is addressed. If the reader of
this message is not the intended recipient or an agent or designee of the
intended recipient, please note that any review, use, disclosure or
distribution of this message or its attachments, in any form, is strictly
prohibited. If you have received this message in error, please immediately
notify the sender and/or [email protected] and delete or destroy any
copy of this message and its attachments.