<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: How do I connect to HBase on Sandbox VM from host computer? in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124664#M17787</link>
    <description>&lt;A rel="user" href="https://community.cloudera.com/users/372/enis.html" nodeid="372"&gt;@Enis&lt;/A&gt;&lt;P&gt; Thanks for the tip!  Worked perfectly.&lt;/P&gt;</description>
    <pubDate>Thu, 04 Feb 2016 04:56:26 GMT</pubDate>
    <dc:creator>blezek_daniel</dc:creator>
    <dc:date>2016-02-04T04:56:26Z</dc:date>
    <item>
      <title>How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124661#M17784</link>
      <description>&lt;P&gt;I have setup the HDP Sandbox 2.3.2 under VirtualBox running on my Mac.  I am able to interact with HBase from inside the VM without any problem.  However, when I try to connect via Java from my host, the connection fails.  I have forwarded port 16000 and created a "sandbox.hortonworks.com" entry in /etc/hosts (similar to &lt;A href="https://cindyxiaoxiaoli.wordpress.com/2015/04/27/remote-connect-to-hbase-on-hortonworks-sandbox-with-java/"&gt;this post&lt;/A&gt;).  Here is my Java code:&lt;/P&gt;&lt;PRE&gt;    Configuration conf = HBaseConfiguration.create();
    conf.set("fs.defaultFS", "hdfs://127.0.0.1:8020/");
    conf.set("hbase.zookeeper.property.clientPort", "2181");
    conf.set("hbase.zookeeper.quorum", "sandbox.hortonworks.com");
    conf.set("zookeeper.znode.parent", "/hbase-unsecure");
    HBaseAdmin.checkHBaseAvailable(conf);
&lt;/PRE&gt;&lt;P&gt;&lt;STRONG&gt;Update:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;A more helpful exception than the one below:&lt;/P&gt;&lt;PRE&gt;Master is not running: org.apache.hadoop.hbase.MasterNotRunningException: The node /hbase is not in ZooKeeper. It should have been written by the master. Check the value configured in 'zookeeper.znode.parent'. There could be a mismatch with the one configured in the master.
&lt;/PRE&gt;&lt;P&gt;Not sure why '/hbase' is being used, when I set "zookeeper.znode.parent" to "/hbase-unsecure" explicitly!&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Update #2:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Running the code on the Sandbox gives exactly the same error.  Any help?&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Old: &lt;/STRONG&gt;and I get this exception:&lt;/P&gt;&lt;PRE&gt;org.apache.hadoop.hbase.MasterNotRunningException: com.google.protobuf.ServiceException: org.apache.hadoop.hbase.exceptions.ConnectionClosingException: Call to sandbox.hortonworks.com/127.0.0.1:16000 failed on local exception: org.apache.hadoop.hbase.exceptions.ConnectionClosingException: Connection to sandbox.hortonworks.com/127.0.0.1:16000 is closing. Call id=0, waitTime=47
	at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$StubMaker.makeStub(ConnectionManager.java:1533)
&amp;lt;snip&amp;gt;&lt;/PRE&gt;&lt;P&gt; Any suggestions or help?  Why would HBase be closing my connection?&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 03:42:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124661#M17784</guid>
      <dc:creator>blezek_daniel</dc:creator>
      <dc:date>2016-02-04T03:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124662#M17785</link>
      <description>&lt;P&gt;Instead of specifying the config options, you should ALWAYS copy the /etc/hbase/conf folder and add that to your application classpath so that hbase-site.xml gets picked up from the classpath. See &lt;A href="https://community.hortonworks.com/articles/4091/hbase-client-application-best-practices.html" target="_blank"&gt;https://community.hortonworks.com/articles/4091/hbase-client-application-best-practices.html&lt;/A&gt;. &lt;/P&gt;&lt;P&gt;The other thing is that you  should open up other ports, 16000, 16030, 16010, 16020, 2181. See &lt;A href="http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.0-Win/bk_HDP_Install_Win/content/ref-79239257-778e-42a9-9059-d982d0c08885.1.html" target="_blank"&gt;http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.0-Win/bk_HDP_Install_Win/content/ref-79239257-778e-42a9-9059-d982d0c08885.1.html&lt;/A&gt;. &lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 03:51:12 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124662#M17785</guid>
      <dc:creator>Enis</dc:creator>
      <dc:date>2016-02-04T03:51:12Z</dc:date>
    </item>
    <item>
      <title>Re: How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124663#M17786</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/2096/danielhendrix.html" nodeid="2096"&gt;@Daniel Hendrix&lt;/A&gt;&lt;P&gt;Make sure HBase is running. 16000 port is for ranger KMS so not whats the use of 16000 in this case.&lt;/P&gt;&lt;P&gt;Please follow &lt;A target="_blank" href="http://www.tutorialspoint.com/hbase/hbase_read_data.htm"&gt;this&lt;/A&gt; article for the java example setup &lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 03:54:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124663#M17786</guid>
      <dc:creator>nsabharwal</dc:creator>
      <dc:date>2016-02-04T03:54:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124664#M17787</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/372/enis.html" nodeid="372"&gt;@Enis&lt;/A&gt;&lt;P&gt; Thanks for the tip!  Worked perfectly.&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 04:56:26 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124664#M17787</guid>
      <dc:creator>blezek_daniel</dc:creator>
      <dc:date>2016-02-04T04:56:26Z</dc:date>
    </item>
    <item>
      <title>Re: How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124665#M17788</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/372/enis.html" nodeid="372"&gt;@Enis&lt;/A&gt; Thanks for the input. I am running into the same problem. But, I copied and added the hbase-site.xml to my mac host laptop. Are other file needed as well within (under like: /etc/hbase/conf/core-site.xml)And, now I am running into :&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOG of relevant properties set correctly:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;conf.Configuration (Configuration.java:getConfResourceAsInputStream(2355)) - found resource hbase-site.xml at file:/etc/hbase/conf/hbase-site.xml
2016-09-27 12:21:22,651 INFO  [main] hbasetest.ConnectHBase (ConnectHBase.java:main(61)) - hbase.zookeeper.quorum:/hbase-unsecure
2016-09-27 12:21:22,651 INFO  [main] hbasetest.ConnectHBase (ConnectHBase.java:main(62)) - hbase.zookeeper.quorum:hdfs://sandbox.hortonworks.com:8020
2016-09-27 12:21:22,651 INFO  [main] hbasetest.ConnectHBase (ConnectHBase.java:main(63)) - hbase.zookeeper.quorum:2181&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Exception:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;code&amp;gt;&lt;/P&gt;&lt;P&gt;where applicable
2016-09-27 12:21:28,045 INFO  [main] zookeeper.RecoverableZooKeeper (RecoverableZooKeeper.java:&amp;lt;init&amp;gt;(120)) - Process identifier=hconnection-0x22c86919 connecting to ZooKeeper ensemble=sandbox.hortonworks.com:2181
2016-09-27 12:21:31,461 INFO  [main] client.ConnectionManager$HConnectionImplementation (ConnectionManager.java:closeZooKeeperWatcher(1682)) - Closing zookeeper sessionid=0x1569fdbdb97003f
Exception in thread "main" org.apache.hadoop.hbase.MasterNotRunningException: com.google.protobuf.ServiceException: java.net.ConnectException: Connection refused
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$StubMaker.makeStub(ConnectionManager.java:1539)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$MasterServiceStubMaker.makeStub(ConnectionManager.java:1559)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation.getKeepAliveMasterService(ConnectionManager.java:1710)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation.isMasterRunning(ConnectionManager.java:928)
at org.apache.hadoop.hbase.client.HBaseAdmin.checkHBaseAvailable(HBaseAdmin.java:2877)
at com.plantronics.data.storm.hbasetest.ConnectHBase.main(ConnectHBase.java:68)
Caused by: com.google.protobuf.ServiceException: java.net.ConnectException: Connection refused
at org.apache.hadoop.hbase.ipc.AbstractRpcClient.callBlockingMethod(AbstractRpcClient.java:223)
at org.apache.hadoop.hbase.ipc.AbstractRpcClient$BlockingRpcChannelImplementation.callBlockingMethod(AbstractRpcClient.java:287)
at org.apache.hadoop.hbase.protobuf.generated.MasterProtos$MasterService$BlockingStub.isMasterRunning(MasterProtos.java:53657)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$MasterServiceStubMaker.isMasterRunning(ConnectionManager.java:1570)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$StubMaker.makeStubNoRetries(ConnectionManager.java:1508)
at org.apache.hadoop.hbase.client.ConnectionManager$HConnectionImplementation$StubMaker.makeStub(ConnectionManager.java:1530)
... 5 more
Caused by: java.net.ConnectException: Connection refused
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717)
at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)
at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:531)
at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:495)
at org.apache.hadoop.hbase.ipc.RpcClientImpl$Connection.setupConnection(RpcClientImpl.java:410)
at org.apache.hadoop.hbase.ipc.RpcClientImpl$Connection.setupIOstreams(RpcClientImpl.java:716)
at org.apache.hadoop.hbase.ipc.RpcClientImpl$Connection.writeRequest(RpcClientImpl.java:887)
at org.apache.hadoop.hbase.ipc.RpcClientImpl$Connection.tracedWriteRequest(RpcClientImpl.java:856)
at org.apache.hadoop.hbase.ipc.RpcClientImpl.call(RpcClientImpl.java:1200)
at org.apache.hadoop.hbase.ipc.AbstractRpcClient.callBlockingMethod(AbstractRpcClient.java:213)
... 10 more
Disconnected from the target VM, address: '127.0.0.1:51389', transport: 'socket' &lt;/P&gt;&lt;P&gt;&amp;lt;/code&amp;gt;&lt;/P&gt;&lt;P&gt;Wondering if this is port opening issue. Is there a horton help page similar to this for &lt;/P&gt;&lt;P&gt;Seeing a exception for connection opening here:&lt;/P&gt;&lt;P&gt;java.nio.channels.SocketChannel[connection-pending remote=sandbox.hortonworks.com/192.168.56.101:16000]&lt;/P&gt;&lt;P&gt;sandbox.hortonworks.com 16000 (Not able to connect here)&lt;/P&gt;&lt;P&gt;&lt;A href="http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.0-Win/bk_HDP_Install_Win/content/ref-79239257-778e-42a9-9059-d982d0c08885.1.html"&gt;http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.0-Win/bk_HDP_Install_Win/content/ref-79239257-778e-42a9-9059-d982d0c08885.1.html&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;for mac/linux? &lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2016 03:37:47 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/124665#M17788</guid>
      <dc:creator>manoj_ramakrish</dc:creator>
      <dc:date>2016-09-28T03:37:47Z</dc:date>
    </item>
    <item>
      <title>Re: How do I connect to HBase on Sandbox VM from host computer?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/295322#M17789</link>
      <description>&lt;P&gt;20-05-04 04:25:52 DEBUG ClientCnxn:818 - Reading reply sessionid:0x171dc5f77f00040, packet:: clientPath:null serverPath:null finished:false header:: 23,3 replyHeader:: 23,1099,0 request:: '/hbase-unsecure,F response:: s{116,116,1477381693974,1477381693974,0,24,0,0,0,18,966}&lt;BR /&gt;2020-05-04 04:25:52 DEBUG ClientCnxn:717 - Got ping response for sessionid: 0x171dc5f77f00040 after 4ms&lt;BR /&gt;2020-05-04 04:25:52 DEBUG ClientCnxn:818 - Reading reply sessionid:0x171dc5f77f00040, packet:: clientPath:null serverPath:null finished:false header:: 24,4 replyHeader:: 24,1099,0 request:: '/hbase-unsecure/master,F response:: #ffffffff000146d61737465723a3136303030ffffffe330ffffff86ffffffafffffffd2352bffffffc850425546a23a1773616e64626f782e686f72746f6e776f726b732e636f6d10ffffff807d18ffffff95ffffffcaffffffbdffffffe3ffffff9d2e10018ffffff8a7d,s{938,938,1588541230259,1588541230259,0,0,0,104106568998453260,71,0,938}&lt;BR /&gt;2020-05-04 04:25:52 DEBUG RpcClientImpl:351 - Use SIMPLE authentication for service MasterService, sasl=false&lt;BR /&gt;2020-05-04 04:25:52 DEBUG RpcClientImpl:716 - Connecting to sandbox.hortonworks.com/127.0.0.1:16000&lt;BR /&gt;2020-05-04 04:25:54 INFO RpcRetryingCaller:132 - Call exception, tries=10, retries=35, started=64734 ms ago, cancelled=false, msg=&lt;/P&gt;</description>
      <pubDate>Sun, 03 May 2020 22:56:15 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-do-I-connect-to-HBase-on-Sandbox-VM-from-host-computer/m-p/295322#M17789</guid>
      <dc:creator>rahulsharma</dc:creator>
      <dc:date>2020-05-03T22:56:15Z</dc:date>
    </item>
  </channel>
</rss>

