title: Hive query HBase so slow
body: <p>I want to use Hive to query the data which is HBase table, like:</p>
  
  <pre><code>100         column=cf1:val, timestamp=1379536809907, value=val_100
  </code></pre>
  
  <p>And I type the following command in hive:</p>
  
  <pre><code>select * from hbase_table where value = 'val_100';
  </code></pre>
  
  <p>I believe everything has been set up. When I type the above command, it shows me like this:</p>
  
  <pre><code>Total MapReduce jobs = 1
  Launching Job 1 out of 1
  Number of reduce tasks is set to 0 since there's no reduce operator
  Starting Job = job_201309031344_0024, Tracking URL =        http://namenode:50030/jobdetails.jsp?jobid=job_201309031344_0024
  Kill Command = /usr/libexec/../bin/hadoop job  -kill job_201309031344_0024
  Hadoop job information for Stage-1: number of mappers: 1; number of reducers: 0
  2013-09-18 14:45:53,815 Stage-1 map = 0%,  reduce = 0%
  2013-09-18 14:46:54,654 Stage-1 map = 0%,  reduce = 0%
  2013-09-18 14:47:55,449 Stage-1 map = 0%,  reduce = 0%
  2013-09-18 14:48:56,193 Stage-1 map = 0%,  reduce = 0%
  2013-09-18 14:49:56,990 Stage-1 map = 0%,  reduce = 0%
  </code></pre>
  
  <p>Why the map task is always 0%? What's wrong with it? Does any place which I do not configure?</p>
  
  <p>I find the error in datanode log file :</p>
  
  <pre><code>2013-09-18 15:18:27,415 INFO org.apache.zookeeper.ClientCnxn: 
  Opening socket connection to server datanode2/192.168.1.97:2181. 
  Will not attempt to authenticate using SASL (unknown error)
  
  2013-09-18 15:18:27,417 WARN org.apache.zookeeper.ClientCnxn: 
  Session 0x0 for server null, unexpected error, closing socket 
  connection and attempting reconnect java.net.ConnectException: 
  Connection refused at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) 
  at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:692)
  at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) 
  at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068)
  </code></pre>