0
votes

I have set up Hadoop and Hbase in pseudo distributed mode on machine A. I am running my client ( Java program ) from machine B.(Machine A and B can communicate with each other). But i am facing problem in doing so.

My client code looks like this :

Configuration config = HBaseConfiguration.create();
config.set("hbase.zookeeper.quorum" ,zookeeperLocation); config.set("hbase.zookeeper.property.clientPort","2181");
HtablePool tablePool = new HTablePool(config,Integer.MAX_VALUE); HTableInterface table = tablePool.getTable(tableName);

My code gets hang on last line( tablePool.getTable() ) and does not proceed. In ZooKeeper logs , i see that request was received to connect but some how it did not proceed ahead. I am really confused. Please help here.

1

1 Answers

2
votes

I got solution to this problem , I tried different things like 1) replacing hostname with ip addresses in all configuration files 2) playing with /etc/hosts file 3) stopping and starting both hadoop and hbase.