Hbase 伪分布式安装 - UbuntuServer2204
安装伪分布Hadoop
安装 zookeeper
mkdir /export/data/zookeeper/data -p
mkdir /export/data/zookeeper/log -p
cd /export/softpackages/
tar -xvf apache-zookeeper-3.8.4-bin.tar.gz
mv apache-zookeeper-3.8.4-bin /export/servers/zookeeper-3.8.4
cd /export/servers/zookeeper-3.8.4/conf/
cp zoo_sample.cfg zoo.cfg
vim zoo.cfg
server.1=IP地址:2888:3888
dataDir=/export/data/zookeeper/data
dataDirLog=/export/data/zookeeper/log
clientPort=2181
echo 1 > /export/servers/zookeeper-3.8.4/myid
sudo vim /etc/profile
# zookeeper 环境变量配置
export ZOOKEEPER_HOME=/export/servers/zookeeper-3.8.4
export PATH=export PATH=$ZOOKEEPER_HOME/bin:$PATH
source /etc/profile
zkServer.sh start
安装 Hbase
cd /export/softpackages/
tar -xvf hbase-2.5.8-bin.tar.gz
mv hbase-2.5.8 /export/servers/
sudo vim /etc/profile
# hbase 环境变量
HBASE_HOME=/export/servers/hbase-2.5.8
export PATH=$HBASE_HOME/bin:$PATH
source /etc/profile
vim /export/servers/hbase-2.5.8/conf/hbase-env.sh
export JAVA_HOME=/export/servers/jdk8
export HBASE_MANAGES_ZK=false
vim /export/servers/hbase-2.5.8/conf/hbase-site.xml
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.wal.provider</name>
<value>filesystem</value>
</property>
<property>
<name>hbase.tmp.dir</name>
<value>./tmp</value>
</property>
<property>
<name>hbase.rootdir</name>
<value>hdfs://127.0.0.1:9000/hbase</value>
</property>
<property>
<name>hbase.zookeeper.property.dataDir</name>
<value>/export/data/zookeeper/data/</value>
</property>
<property>
<name>hbase.unsafe.stream.capability.enforce</name>
<value>false</value>
</property>
<property>
<name>hbase.zookeeper.property.clientPort</name>
<value>2181</value>
<description>Property from ZooKeeper's config zoo.cfg.The port at which the clients will connect.</description>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>192.168.52.128</value>
<description>Comma separated list of servers in the ZooKeeper Quorum.</description>
</property>
</configuration>
启动 hbase
start-hbase.sh
链接 hbase
hbase shell