Centos7 install HBase 1.6.0


Installation and configuration of HBase 1.6.0

Installation and configuration of zookeeper

1. HBase depends on zookeeper, which needs to be installed before use

wget https://mirrors.tuna.tsinghua.edu.cn/apache/zookeeper/zookeeper-3.4.14/zookeeper-3.4.14.tar.gz
tar -zxvf zookeeper-3.4.14.tar.gz
mv zookeeper-3.4.14 zookeeper

2. Configuration

#The internal configuration can remain unchanged and only one copy is needed
cd zookeeper/conf
cp zoo_sample.cfg zoo.cfg

3. Start zookeeper

cd zookeeper/bin
./zkServer.sh start

HBase installation and configuration

1. Download and decompress

wget https://mirrors.tuna.tsinghua.edu.cn/apache/hbase/1.6.0/hbase-1.6.0-bin.tar.gz
tar -zxvf hbase-1.6.0-bin.tar.gz
mv hbase-1.6.0-bin hbase

2. Configuration

cd hbase/conf
vim hbase-env.sh
#Edit HBase- env.sh File, change one parameter to false. That is to use the external zookeeper
export HBASE_MANAGES_ZK=false

vim hbase-site.xml
#Edit the HBase configuration file and write the following
Wei hbase.zookeeper.quorum Item can not be configured temporarily because it is pseudo distributed

3. Start up

cd hbase/bin
#The JPS command can be used to see if the startup is successful
#92001 hmaster (for successful startup)
# 92512 Jps
# 92184 HRegionServer
# 39610 RunJar
# 38475 NameNode
# 39421 NodeManager
# 38638 DataNode
# 38846 SecondaryNameNode
# 39102 ResourceManager

#Using HBase shell
./hbase shell

Error warning


Java HotSpot(TM) 64-Bit Server VM warning: ignoring option PermSize=128m; support was removed in 8.0
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=128m; support was removed in 8.0

terms of settlement:

vim hbase/conf/hbase-env.sh
#Comment out the following two lines
export HBASE_MASTER_OPTS="$HBASE_MASTER_OPTS -XX:PermSize=128m -XX:MaxPermSize=128m -XX:ReservedCodeCacheSize=256m"
export HBASE_REGIONSERVER_OPTS="$HBASE_REGIONSERVER_OPTS -XX:PermSize=128m -XX:MaxPermSize=128m -XX:ReservedCodeCacheSize=256m"