I run hbase with start-hbase.sh
, but the log file output exception as follow:
2015-09-12 18:39:37,935 WARN [RS:0;roger-ubuntu:54809-SendThread(localhost:2181)] zookeeper.ClientCnxn: Session 0x14fc12354a40004 for server null, unexpected error, closing socket connection and attempting reconnect
java.net.ConnectException: 拒绝连接
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:740)
at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:361)
at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1081)
According to Exception, hbase can not connect to zookeeper, but this hbase should run a zookeeper for self.
here is my hbase-site.xml
:
<configuration>
<property>
<name>hbase.coprocessor.region.classes</name>
<value>com.gzhdi.coprocessor.HelloWorldEndPoint</value>
</property>
</configuration>
and my hbase-env.sh
:
export HBASE_OPTS="-XX:+UseConcMarkSweepGC"