毕业论文开发语言企业开发JAVA技术.NET技术WEB开发Linux/Unix数据库技术Windows平台移动平台嵌入式论文范文英语论文
您现在的位置: 毕业论文 >> 数据库 >> 正文

hbase 启动zookeeper失败拒绝连接

更新时间:2014-10-23:  来源:毕业论文

base-hadoop-regionserver-datatestnode.log
Plain Text code

2014-01-16 19:11:11,875 INFO org.apache.zookeeper.ClientCnxn: Opening socket connection to server nametestnode/192.168.31.92:2181. Will not attempt to authenticate using SASL (unknown error)
2014-01-16 19:11:11,876 WARN org.apache.zookeeper.ClientCnxn: Session 0x0 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:735)
        at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350)
        at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068)
2014-01-16 19:25:18,481 INFO org.apache.zookeeper.ClientCnxn: Opening socket connection to server datatestnode/192.168.31.67:2181. Will not attempt to authenticate using SASL (unknown error)
2014-01-16 19:25:18,481 WARN org.apache.zookeeper.ClientCnxn: Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect
java.net.ConnectException: 拒绝连接


如果我手动使用hbase-daemon.sh start zookeeper 启动namenode和datanode上的zookeeper没问题
用zkServer.sh status 可以看到一个是leader一个是follower
但是用start-hbase.sh 就会报上面那个错误
防火墙已关,ssh没问题,hadoop已启动,namenode和datanode的hdfs都ok
datanode服务器上文件都是从namenode上scp过去的,不存在版本不一致的问题
我的配置:
/etc/hosts:
192.168.31.92   nametestnode
192.168.31.67   datatestnode
hostname也没有问题
hbase-env.sh :
export HBASE_MANAGES_ZK=false

hbase-site.xml
Plain Text code
 
<configuration>
<property>
<name>hbase.rootdir</name>
<value>hdfs://nametestnode:9000/data01/hadoop/data/dfs.data.dir</value>
</property>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.master</name>
<value>hdfs://nametestnode:9002</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>nametestnode</value>                         
</property>
<property>
<name>hbase.zookeeper.property.dataDir</name>
<value>/data01/hadoop/runtimes/zookeeper/data</value>
</property>
 
</configuration>

zoo.cfg
 
# The number of milliseconds of each tick
tickTime=2000
# The number of ticks that the initial
# synchronization phase can take
initLimit=10
# The number of ticks that can pass between
# sending a request and getting an acknowledgement
syncLimit=5
# the directory where the snapshot is stored.
# do not use /tmp for storage, /tmp here is just
# example sakes.
dataDir=/data01/hadoop/runtimes/zookeeper/data
# the port at which the clients will connect
clientPort=2181
#
# Be sure to read the maintenance section of the
# administrator guide before turning on autopurge.
#
#
# The number of snapshots to retain in dataDir
#autopurge.snapRetainCount=3
# Purge task interval in hours
# Set to "0" to disable auto purge feature
#autopurge.purgeInterval=1
dataLogDir=/data01/hadoop/runtimes/zookeeper/logs
server.1=nametestnode:2888:3888
server.2=datatestnode:2888:3888 

记得start-hbase.sh调用的就是hbase-daemon.sh脚本
应该不是脚本BUG

<name>hbase.zookeeper.quorum</name>
<value>nametestnode</value>    

你的配置只链接了nametestnode节点,把datatestnode也配到链接上去
或者修改zoo.cfg
server.2=datatestnode:2888:3888  把这个去掉,只启动单节点ZK

设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©youerw.com 优尔论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。