gpt4 book ai didi

hadoop - 使用importtsv将数据加载到HBASE中会导致错误

转载 作者:行者123 更新时间:2023-12-02 21:46:05 26 4
gpt4 key购买 nike

我正在尝试使用importtsv工具将数据从CSV文件加载到HBASE中。我已经建立了3台机器的集群。
这是我的hbase-site.xml文件

<configuration>
<property>
<name>hbase.rootdir</name>
<value>hdfs://ec2-54-190-103-64.us-west-2.compute.amazonaws.com:9000/hbase</value>
</property>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>ec2-54-203-95-235.us-west-2.compute.amazonaws.com</value>
</property>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>

<property>
<name>hbase.zookeeper.property.clientPort</name>
<value>2222</value>
</property>
<property>
<name>hbase.zookeeper.property.dataDir</name>
<value>/home/ubuntu/zookeeper</value>
<description>Property from ZooKeeper's config zoo.cfg.
The directory where the snapshot is stored.
</description>
</property>
</configuration>

当我启动并运行jps时。在主节点下,我看到HMaster,在数据节点下,我看到Hquorumpeer和Hregionserver
当我尝试加载数据时出现以下错误
INFO zookeeper.ClientCnxn: Opening socket connection to server       localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error)
14/08/11 07:41:28 WARN 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:739)
at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350)
at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068)
14/08/11 07:41:28 WARN zookeeper.RecoverableZooKeeper: Possibly transient ZooKeeper exception: org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /hbase
14/08/11 07:41:28 INFO util.RetryCounter: Sleeping 8000ms before retry #3...
14/08/11 07:41:29 INFO zookeeper.ClientCnxn: Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error)

不知道Zookeeper有什么问题。提前致谢

最佳答案

您需要在hbase-site.xml文件中添加以下属性(主服务器和从服务器)

<property>
<name>hbase.zookeeper.property.maxClientCnxns</name>
<value>1000</value>
</property>

关于hadoop - 使用importtsv将数据加载到HBASE中会导致错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25238160/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com